From: ryani33 Date: Sat, 25 Feb 2017 04:32:40 +0000 (+0800) Subject: fix deprecated warning X-Git-Tag: 2.4.2~1^2^2 X-Git-Url: https://git.immae.eu/?a=commitdiff_plain;h=8bdff27290a98fc2cfbc9d516b011a399af01b5c;p=github%2Ffretlink%2Fpurs-loader.git fix deprecated warning --- diff --git a/package.json b/package.json index 09301db..f16ee86 100644 --- a/package.json +++ b/package.json @@ -42,7 +42,7 @@ "debug": "^2.2.0", "globby": "^4.0.0", "js-string-escape": "^1.0.1", - "loader-utils": "^0.2.14", + "loader-utils": "^1.0.2", "promise-retry": "^1.1.0" }, "devDependencies": { diff --git a/src/index.js b/src/index.js index 249f472..e49fd2c 100644 --- a/src/index.js +++ b/src/index.js @@ -18,7 +18,7 @@ const requireRegex = /require\(['"]\.\.\/([\w\.]+)['"]\)/g module.exports = function purescriptLoader(source, map) { const callback = this.async() const config = this.options - const query = loaderUtils.parseQuery(this.query) + const query = loaderUtils.getOptions(this) || {} const webpackOptions = this.options.purescriptLoader || {} const depsPaths = (pscPackage => {