Skip to content

Commit

Permalink
fix(index): 'Cannot create property prev on boolean false' (`opti…
Browse files Browse the repository at this point in the history
…ons.sourceMap`)
  • Loading branch information
michael-ciniawsky committed May 8, 2017
1 parent e586f4a commit c4f0064
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions lib/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -69,14 +69,14 @@ module.exports = function loader (css, map) {
: rc.ctx.options = {}
}

delete options.config

const sourceMap = options.sourceMap

delete options.sourceMap

Promise.resolve().then(() => {
if (Object.keys(options).length !== 0) {
if (
Object.keys(options).length !== 0 ||
((rc || sourceMap) && Object.keys(options).length > 1) ||
((rc && sourceMap) && Object.keys(options).length > 2)
) {
return parseOptions.call(this, options)
}

Expand Down

0 comments on commit c4f0064

Please sign in to comment.