mirror of
https://github.com/whoisclebs/lodash.git
synced 2026-01-31 23:37:49 +00:00
re-styling previous commit.
This commit is contained in:
@@ -595,9 +595,10 @@
|
||||
|
||||
// Returns a function that will only be executed after being called N times.
|
||||
_.after = function(times, func) {
|
||||
return times ? function() {
|
||||
if (times <= 0) return func();
|
||||
return function() {
|
||||
if (--times < 1) { return func.apply(this, arguments); }
|
||||
} : func();
|
||||
};
|
||||
};
|
||||
|
||||
// Object Functions
|
||||
|
||||
Reference in New Issue
Block a user