]> _ Git - fluidbook-html5.git/commitdiff
#1675
authorVincent Vanwaelscappel <vincent@cubedesigners.com>
Wed, 20 Sep 2017 14:38:37 +0000 (16:38 +0200)
committerVincent Vanwaelscappel <vincent@cubedesigners.com>
Wed, 20 Sep 2017 14:38:37 +0000 (16:38 +0200)
js/libs/fluidbook/fluidbook.search.js

index 7285c9541e23b040c788425f16ae80296560ce19..a40e4aedf262281cb96dc0be28d72bf649646a09 100644 (file)
@@ -39,17 +39,15 @@ FluidbookSearch.prototype = {
         }
         var $this = this;
         loadJSLibrary('data/search.index.js', function () {
-            loadJSLibrary('data/search.texts.js', function () {
-                if ($this.highlightEnabled) {
-                    loadJSLibrary('data/search.highlight.js', function () {
-                        $this.indexLoaded = true;
-                        callback();
-                    });
-                } else {
+            if ($this.highlightEnabled) {
+                loadJSLibrary('data/search.highlight.js', function () {
                     $this.indexLoaded = true;
                     callback();
-                }
-            });
+                });
+            } else {
+                $this.indexLoaded = true;
+                callback();
+            }
         });
     },
     _getHints: function (q, callback) {