Replace variable swap with a one-liner.
This commit is contained in:
parent
e584e05f5e
commit
572612a282
1 changed files with 1 additions and 3 deletions
|
@ -417,9 +417,7 @@ function onclick_select(event)
|
|||
let end_index = video_cards.indexOf(event.target);
|
||||
if (end_index < start_index)
|
||||
{
|
||||
let temp = start_index;
|
||||
start_index = end_index;
|
||||
end_index = temp;
|
||||
[start_index, end_index] = [end_index, start_index];
|
||||
}
|
||||
|
||||
for (let index = start_index; index <= end_index; index += 1)
|
||||
|
|
Loading…
Reference in a new issue