my-idlers/node_modules/collect.js/dist/methods/unless.js

9 lines
138 B
JavaScript
Raw Normal View History

'use strict';
module.exports = function when(value, fn, defaultFn) {
if (!value) {
fn(this);
} else {
defaultFn(this);
}
};