From: Rick Waldron Date: Tue, 17 May 2011 00:16:18 +0000 (-0400) Subject: [#520] Quick lint fix; idx already defined X-Git-Tag: v0.6~2^2~8^2 X-Git-Url: http://git.khamidou.com/?a=commitdiff_plain;h=7f586647584ce8a89e9e17ae7f8d1ee5b8588360;p=popcorn-js.git [#520] Quick lint fix; idx already defined --- diff --git a/popcorn.js b/popcorn.js index 42c0094..9721167 100644 --- a/popcorn.js +++ b/popcorn.js @@ -578,9 +578,10 @@ // Store this definition in an array sorted by times var byStart = obj.data.trackEvents.byStart, - byEnd = obj.data.trackEvents.byEnd; + byEnd = obj.data.trackEvents.byEnd, + idx; - for ( var idx = byStart.length-1; idx >= 0; idx-- ) { + for ( idx = byStart.length-1; idx >= 0; idx-- ) { if ( track.start >= byStart[idx].start ) { byStart.splice( idx+1, 0, track ); @@ -588,7 +589,7 @@ } } - for ( var idx = byEnd.length-1; idx >= 0; idx-- ) { + for ( idx = byEnd.length-1; idx >= 0; idx-- ) { if ( track.start >= byEnd[idx].start ) { byEnd.splice( idx+1, 0, track );