diff --git a/LICENSE b/LICENSE index c3a953a51..d8174a263 100644 --- a/LICENSE +++ b/LICENSE @@ -1,5 +1,5 @@ /* -* 4chan X - Version 1.1.3 - 2013-04-28 +* 4chan X - Version 1.1.3 - 2013-04-30 * * Licensed under the MIT license. * https://github.com/seaweedchan/4chan-x/blob/master/LICENSE diff --git a/builds/4chan-X.js b/builds/4chan-X.js index 935cc190e..757285a8b 100644 --- a/builds/4chan-X.js +++ b/builds/4chan-X.js @@ -18,7 +18,7 @@ // @icon data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwAgMAAAAqbBEUAAAACVBMVEUAAGcAAABmzDNZt9VtAAAAAXRSTlMAQObYZgAAAHFJREFUKFOt0LENACEIBdBv4Qju4wgWanEj3D6OcIVMKaitYHEU/jwTCQj8W75kiVCSBvdQ5/AvfVHBin11BgdRq3ysBgfwBDRrj3MCIA+oAQaku/Q1cNctrAmyDl577tOThYt/Y1RBM4DgOHzM0HFTAyLukH/cmRnqAAAAAElFTkSuQmCC // ==/UserScript== /* -* 4chan X - Version 1.1.3 - 2013-04-28 +* 4chan X - Version 1.1.3 - 2013-04-30 * * Licensed under the MIT license. * https://github.com/seaweedchan/4chan-x/blob/master/LICENSE @@ -335,7 +335,7 @@ i = this.length; while (i--) { if (this[i] === object) { - break; + return i; } } return i; @@ -349,6 +349,7 @@ arg = args[_i]; this.push.apply(this, arg); } + return this; }; Array.prototype.remove = function(object) { diff --git a/builds/4chan-X.user.js b/builds/4chan-X.user.js index a58c32940..2466ac03f 100644 --- a/builds/4chan-X.user.js +++ b/builds/4chan-X.user.js @@ -18,7 +18,7 @@ // @icon data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwAgMAAAAqbBEUAAAACVBMVEUAAGcAAABmzDNZt9VtAAAAAXRSTlMAQObYZgAAAHFJREFUKFOt0LENACEIBdBv4Qju4wgWanEj3D6OcIVMKaitYHEU/jwTCQj8W75kiVCSBvdQ5/AvfVHBin11BgdRq3ysBgfwBDRrj3MCIA+oAQaku/Q1cNctrAmyDl577tOThYt/Y1RBM4DgOHzM0HFTAyLukH/cmRnqAAAAAElFTkSuQmCC // ==/UserScript== /* -* 4chan X - Version 1.1.3 - 2013-04-28 +* 4chan X - Version 1.1.3 - 2013-04-30 * * Licensed under the MIT license. * https://github.com/seaweedchan/4chan-x/blob/master/LICENSE @@ -332,7 +332,7 @@ i = this.length; while (i--) { if (this[i] === object) { - break; + return i; } } return i; @@ -346,6 +346,7 @@ arg = args[_i]; this.push.apply(this, arg); } + return this; }; Array.prototype.remove = function(object) { diff --git a/builds/crx/script.js b/builds/crx/script.js index 5905614b9..f35257445 100644 --- a/builds/crx/script.js +++ b/builds/crx/script.js @@ -1,5 +1,5 @@ /* -* 4chan X - Version 1.1.3 - 2013-04-28 +* 4chan X - Version 1.1.3 - 2013-04-30 * * Licensed under the MIT license. * https://github.com/seaweedchan/4chan-x/blob/master/LICENSE @@ -314,7 +314,7 @@ i = this.length; while (i--) { if (this[i] === object) { - break; + return i; } } return i; @@ -328,6 +328,7 @@ arg = args[_i]; this.push.apply(this, arg); } + return this; }; Array.prototype.remove = function(object) { diff --git a/src/General/lib/$.coffee b/src/General/lib/$.coffee index f5cccad99..8c8d4713e 100644 --- a/src/General/lib/$.coffee +++ b/src/General/lib/$.coffee @@ -16,14 +16,14 @@ Array::contains = (object) -> Array::indexOf = (object) -> i = @length while i-- - break if @[i] is object + return i if @[i] is object return i Array::pushArrays = -> args = arguments for arg in args @push.apply @, arg - return + return @ Array::remove = (object) -> if (index = @indexOf object) > -1