From dd61cfae36957856dc9c7dd19a46a22ae61bfc6b Mon Sep 17 00:00:00 2001 From: Maxime Bernard Date: Thu, 31 Mar 2016 18:52:38 +0200 Subject: [PATCH] Fix "module not available" error --- dist/ws-script-loader.js | 2 +- dist/ws-script-loader.min.js | 2 +- src/wsScriptLoader.js | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/dist/ws-script-loader.js b/dist/ws-script-loader.js index 59bb65d..1caffc6 100755 --- a/dist/ws-script-loader.js +++ b/dist/ws-script-loader.js @@ -1,7 +1,7 @@ (function() { -angular.module('wsScriptLoader') +angular.module('wsScriptLoader', []) .service('wsScriptLoader', ["$q", function($q) { var service = this; diff --git a/dist/ws-script-loader.min.js b/dist/ws-script-loader.min.js index 6ad93fe..e77a66b 100755 --- a/dist/ws-script-loader.min.js +++ b/dist/ws-script-loader.min.js @@ -1 +1 @@ -!function(){angular.module("wsScriptLoader").service("wsScriptLoader",["$q",function(e){var r=this,n=[];r.insertScriptTag=function(e,r){if(n.indexOf(e)<0){var i=document.createElement("script");i.src=e,i.onload=r,document.body.appendChild(i),n.push(e)}else r()},r.loadScriptTag=function(n){var i=e.defer();return r.insertScriptTag(n,function(){i.resolve()}),i.promise}}])}(); \ No newline at end of file +!function(){angular.module("wsScriptLoader",[]).service("wsScriptLoader",["$q",function(e){var r=this,n=[];r.insertScriptTag=function(e,r){if(n.indexOf(e)<0){var i=document.createElement("script");i.src=e,i.onload=r,document.body.appendChild(i),n.push(e)}else r()},r.loadScriptTag=function(n){var i=e.defer();return r.insertScriptTag(n,function(){i.resolve()}),i.promise}}])}(); \ No newline at end of file diff --git a/src/wsScriptLoader.js b/src/wsScriptLoader.js index eedae71..67fb3bb 100755 --- a/src/wsScriptLoader.js +++ b/src/wsScriptLoader.js @@ -1,4 +1,4 @@ -angular.module('wsScriptLoader') +angular.module('wsScriptLoader', []) .service('wsScriptLoader', function($q) { var service = this;