Skip to content

Commit

Permalink
Drop dependency on deprecated gulp-util (#158)
Browse files Browse the repository at this point in the history
Closes #157
  • Loading branch information
demurgos authored and dylans committed Dec 31, 2017
1 parent 9ed0670 commit a50dbf6
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,9 @@
},
"dependencies": {
"amdefine": "^1.0.0",
"gulp-util": "3.0.7",
"istanbul": "0.4.5",
"minimatch": "^3.0.3",
"plugin-error": "^0.1.2",
"source-map": ">=0.5.6",
"through2": "2.0.1"
},
Expand Down
8 changes: 4 additions & 4 deletions src/gulpRemapIstanbul.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import remap from './remap';
import writeReport from './writeReport';
import checkThreshold from './checkThreshold';
import MemoryStore from '../utils/node!istanbul/lib/store/memory';
import { PluginError } from '../utils/node!gulp-util';
import PluginError from '../utils/node!plugin-error';
import through from '../utils/node!through2';

/* global Promise */
Expand Down Expand Up @@ -34,7 +34,7 @@ export default function gulpPlugin(opts = {}) {
const collector = remap(JSON.parse(file.contents.toString('utf8')), opts);

let thresholdCheckFailed = false;
if (opts.check) {
if (opts.check) {
thresholdCheckFailed = checkThreshold(opts.check, collector);
}

Expand All @@ -54,10 +54,10 @@ export default function gulpPlugin(opts = {}) {

Promise.all(p).then(() => {
if (thresholdCheckFailed) {
return cb(new PluginError('remap-istanbul', 'Coverage threshold not met'));
return cb(new PluginError('remap-istanbul', 'Coverage threshold not met'));
} else {
cb(null, file);
}
}
});
});
};

0 comments on commit a50dbf6

Please sign in to comment.