Add placeholders to fp wrapper. [closes #1780]

This commit is contained in:
John-David Dalton
2016-01-13 22:06:11 -08:00
parent ff5f06b9f0
commit 7544166d11
3 changed files with 32 additions and 2 deletions

View File

@@ -1,5 +1,6 @@
var mapping = require('./mapping.js'),
mutateMap = mapping.mutate;
mutateMap = mapping.mutate,
placeholder = {};
/**
* The base implementation of `convert` which accepts a `util` object of methods
@@ -176,7 +177,12 @@ function baseConvert(util, name, func) {
});
return !result;
});
return result || func;
result || (result = func);
if (mapping.placeholder[name]) {
result.placeholder = placeholder;
}
return result;
};
if (!isLib) {