Ensure LodashWrapper.prototype.thru exists before creating a wrapper in flow.

This commit is contained in:
jdalton
2015-05-15 20:36:34 -07:00
parent 46ace7e8e8
commit 3490f8acb5

View File

@@ -3488,7 +3488,7 @@
if (typeof func != 'function') {
throw new TypeError(FUNC_ERROR_TEXT);
}
if (!wrapper && getFuncName(func) == 'wrapper') {
if (!wrapper && LodashWrapper.prototype.thru && getFuncName(func) == 'wrapper') {
wrapper = new LodashWrapper([]);
}
}