mirror of
https://github.com/whoisclebs/lodash.git
synced 2026-02-11 11:27:50 +00:00
Remove unnecessary return statements from _.delay and _.defer.
Former-commit-id: fb912605e8414b1a4d9d2d8ae96f21dfe95609c2
This commit is contained in:
@@ -3284,7 +3284,7 @@
|
|||||||
*/
|
*/
|
||||||
function delay(func, wait) {
|
function delay(func, wait) {
|
||||||
var args = slice.call(arguments, 2);
|
var args = slice.call(arguments, 2);
|
||||||
return setTimeout(function() { return func.apply(undefined, args); }, wait);
|
return setTimeout(function() { func.apply(undefined, args); }, wait);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -3304,7 +3304,7 @@
|
|||||||
*/
|
*/
|
||||||
function defer(func) {
|
function defer(func) {
|
||||||
var args = slice.call(arguments, 1);
|
var args = slice.call(arguments, 1);
|
||||||
return setTimeout(function() { return func.apply(undefined, args); }, 1);
|
return setTimeout(function() { func.apply(undefined, args); }, 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
Reference in New Issue
Block a user