]> source.dussan.org Git - jquery.git/commitdiff
Effect: Fix a unnecessary conditional statement in .stop()
authorWonseop Kim <wonseop.kim@samsung.com>
Wed, 1 May 2019 12:57:55 +0000 (21:57 +0900)
committerMichał Gołębiowski-Owczarek <m.goleb@gmail.com>
Wed, 1 May 2019 12:57:55 +0000 (14:57 +0200)
Because of the above conditional, the 'type' variable has a value of type
'string' or undefined. Therefore, boolean comparisons for 'type' variable
is always unnecessary because it return true. The patch removed the
unnecessary conditional statement.

Fixes gh-4374
Closes gh-4375

src/effects.js

index 147aa065f5ad38ca67b05e6833bf8a4afc81bda5..a65283e285ce0270259c16eaab8a45bad78f6860 100644 (file)
@@ -538,7 +538,7 @@ jQuery.fn.extend( {
                        clearQueue = type;
                        type = undefined;
                }
-               if ( clearQueue && type !== false ) {
+               if ( clearQueue ) {
                        this.queue( type || "fx", [] );
                }