[open-ils-commits] [GIT] Evergreen ILS branch master updated. 6d98ced94170e96ae69a7c4baa3e80377b8de04f

Evergreen Git git at git.evergreen-ils.org
Fri Aug 10 10:22:47 EDT 2018


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "Evergreen ILS".

The branch, master has been updated
       via  6d98ced94170e96ae69a7c4baa3e80377b8de04f (commit)
      from  91d838f48e5931d1e599a7473a9ffce9dbedad47 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 6d98ced94170e96ae69a7c4baa3e80377b8de04f
Author: Bill Erickson <berickxx at gmail.com>
Date:   Thu Aug 9 10:20:54 2018 -0400

    LP#1775719 Modify array check for Phantomjs; reduce logging;
    
    PhantomJS doesn't support the handy [1,2,3].includes(1) function, so
    replace it with the tried-and-true indexOf();
    
    Avoid logging errors on failure to connect to the shared offline worker
    when running within phantomjs.
    
    Signed-off-by: Bill Erickson <berickxx at gmail.com>
    Signed-off-by: Kathy Lussier <klussier at masslnc.org>

diff --git a/Open-ILS/web/js/ui/default/staff/services/lovefield.js b/Open-ILS/web/js/ui/default/staff/services/lovefield.js
index cfd787f..561f900 100644
--- a/Open-ILS/web/js/ui/default/staff/services/lovefield.js
+++ b/Open-ILS/web/js/ui/default/staff/services/lovefield.js
@@ -33,7 +33,10 @@ angular.module('egCoreMod')
         }
 
         service.worker.onerror = function(err) {
-            console.error('Error loading shared worker', err);
+            // avoid spamming unit test runner on failure to connect.
+            if (!navigator.userAgent.match(/PhantomJS/)) {
+                console.error('Error loading shared worker', err);
+            }
             service.cannotConnect = true;
         }
 
@@ -108,7 +111,7 @@ angular.module('egCoreMod')
     // Create and connect to the give schema
     service.connectToSchema = function(schema) {
 
-        if (service.connectedSchemas.includes(schema)) {
+        if (service.connectedSchemas.indexOf(schema) >= 0) {
             // already connected
             return $q.when();
         }

-----------------------------------------------------------------------

Summary of changes:
 .../web/js/ui/default/staff/services/lovefield.js  |    7 +++++--
 1 files changed, 5 insertions(+), 2 deletions(-)


hooks/post-receive
-- 
Evergreen ILS


More information about the open-ils-commits mailing list