Skip to content

Commit 0580e6e

Browse files
committed
Improve U.clearInterval().
1 parent 479ad14 commit 0580e6e

File tree

1 file changed

+1
-3
lines changed
  • src/main/java/com/github/underscore

1 file changed

+1
-3
lines changed

src/main/java/com/github/underscore/U.java

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2765,9 +2765,7 @@ public void run() {
27652765
}
27662766

27672767
public static void clearInterval(java.util.concurrent.ScheduledFuture scheduledFuture) {
2768-
if (scheduledFuture != null) {
2769-
scheduledFuture.cancel(true);
2770-
}
2768+
clearTimeout(scheduledFuture);
27712769
}
27722770

27732771
public static <T> List<T> copyOf(final Iterable<T> iterable) {

0 commit comments

Comments
 (0)