From 29c9d55498a7b51e7706a2e7ba519c71f3eaac80 Mon Sep 17 00:00:00 2001
From: hexeth <7627137+hexeth@users.noreply.github.com>
Date: Fri, 4 Jan 2019 12:49:01 -0800
Subject: [PATCH] Remove leading space in span (#749)

Previous code was not targeting right element, additionally was only removing a single leading space. New regex will remove any leading spaces from span
---
 cps/static/js/caliBlur.js | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/cps/static/js/caliBlur.js b/cps/static/js/caliBlur.js
index 4cf54493..0d80860e 100644
--- a/cps/static/js/caliBlur.js
+++ b/cps/static/js/caliBlur.js
@@ -220,8 +220,8 @@ publisher = $( '.publishers p span' ).text().split( ':' );
   $.each(publisher, function(i, val) {
     $( '.publishers' ).append( '<span>' + publisher[i] + '</span>' );
   });
-$( '.publishers span:nth-child(2)' ).text(function() {
-return $(this).text().replace(/^\s+/g, "");
+$( '.publishers span:nth-child(3)' ).text(function() {
+return $(this).text().replace(/^\s+|^\t+|\t+|\s+$/g, "");
 });
 
   published = $( '.book-meta p:contains("Publishing date")' )
-- 
2.18.1