You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
(Side note on the function naming: I thought the natural numbers set included zero?)
Manual sorting test in node console:
> function sorter(a, b){
... if (a < 1) return 1
... if (b < 1) return -1
... return a - b
... }
undefined
> arr=[1,5,8,0,6,4,9,3]
[
1, 5, 8, 0,
6, 4, 9, 3
]
> arr.sort(sorter)
[
1, 3, 4, 5,
6, 8, 9, 0
]
Display
The queue column's render template seems to ignore the zero value, probably because javascript treats zero as a false-y value, falling back to torrentQueue and it seems this scope var is undefined.
Screenshot
Below is the queue column in the Electorrent app. The purple arrow indicates a torrent that has a position 0 in the queue.
This one is from tremotesf2 app. The purple arrow indicates the same torrent.
The text was updated successfully, but these errors were encountered:
Client:
Client Version: 3.00 (bb6b5a062e)
Operating System: Windows
Application Version: 2.7.1
Description:
Looks like the queue implementation doesn't account for zero-based numbering, either when sorting or displaying values.
The transmission RPC protocol specification states that the queue position value starts at zero.
Sorting
The sorting implementation seems to always push the zero value queue position to last.
(Side note on the function naming: I thought the natural numbers set included zero?)
Manual sorting test in node console:
Display
The queue column's render template seems to ignore the zero value, probably because javascript treats zero as a false-y value, falling back to
torrentQueue
and it seems this scope var is undefined.Screenshot
Below is the queue column in the Electorrent app. The purple arrow indicates a torrent that has a position
0
in the queue.This one is from tremotesf2 app. The purple arrow indicates the same torrent.
The text was updated successfully, but these errors were encountered: