From 456faf400cc2696819213c7ff692ccb9830aa528 Mon Sep 17 00:00:00 2001 From: Niklas Berg Date: Sat, 24 Feb 2018 00:02:19 +0100 Subject: [PATCH] Arcade groups collider --- src/loader/File.js | 6 +++--- src/loader/filetypes/PluginFile.js | 10 +--------- 2 files changed, 4 insertions(+), 12 deletions(-) diff --git a/src/loader/File.js b/src/loader/File.js index 56ed9d9ff..b5beac6f6 100644 --- a/src/loader/File.js +++ b/src/loader/File.js @@ -65,7 +65,7 @@ var File = new Class({ { this.url = GetFastValue(fileConfig, 'path', '') + this.key + '.' + GetFastValue(fileConfig, 'extension', ''); } - else if (typeof(this.url) !== 'function') + else { this.url = GetFastValue(fileConfig, 'path', '').concat(this.url); } @@ -118,7 +118,7 @@ var File = new Class({ * @type {integer} * @since 3.0.0 */ - this.state = typeof(this.url) === "function" ? CONST.FILE_POPULATED : CONST.FILE_PENDING; + this.state = CONST.FILE_PENDING; /** * The total size of this file. @@ -437,4 +437,4 @@ File.revokeObjectURL = function (image) } }; -module.exports = File; +module.exports = File; \ No newline at end of file diff --git a/src/loader/filetypes/PluginFile.js b/src/loader/filetypes/PluginFile.js index 81ab63fb1..8beecc5e3 100644 --- a/src/loader/filetypes/PluginFile.js +++ b/src/loader/filetypes/PluginFile.js @@ -34,14 +34,6 @@ var PluginFile = new Class({ function PluginFile (key, url, path, xhrSettings) { - // If the url variable refers to a class, add the plugin directly - if (typeof url === 'function') - { - this.key = key; - window[key] = url; - window[key].register(PluginManager); - } - var fileKey = (typeof key === 'string') ? key : GetFastValue(key, 'key', ''); var fileConfig = { @@ -115,4 +107,4 @@ FileTypesManager.register('plugin', function (key, url, xhrSettings) return this; }); -module.exports = PluginFile; +module.exports = PluginFile; \ No newline at end of file