From d3a52b6e9e5672e06e69269152b9625ae1152b17 Mon Sep 17 00:00:00 2001 From: pooya parsa Date: Tue, 5 Mar 2019 12:26:13 +0330 Subject: [PATCH] fix(workbox): always prepend routerBase to swURL fixes #157 --- packages/workbox/lib/options.js | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/packages/workbox/lib/options.js b/packages/workbox/lib/options.js index 66dc07a2..3c49e62f 100644 --- a/packages/workbox/lib/options.js +++ b/packages/workbox/lib/options.js @@ -31,9 +31,7 @@ function getOptions (moduleOptions) { } // swURL - if (!options.swURL) { - options.swURL = joinUrl(options.routerBase, 'sw.js') - } + options.swURL = joinUrl(options.routerBase, options.swURL || 'sw.js') // swScope if (!options.swScope) {