[open-ils-commits] [GIT] Evergreen ILS branch rel_3_1 updated. a65b26f4e29a2d1273fde69421625b1a2bff7794

Evergreen Git git at git.evergreen-ils.org
Fri Aug 10 10:24:21 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, rel_3_1 has been updated
       via  a65b26f4e29a2d1273fde69421625b1a2bff7794 (commit)
      from  40a3132236393425cfb8fd4d7d2fee6e984ab62c (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 a65b26f4e29a2d1273fde69421625b1a2bff7794
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