mirror of
https://git.deluge-torrent.org/deluge
synced 2025-08-08 09:28:41 +00:00
Fixed bug that would cause info command to sometimes 'shorten' torrent ID in a way that in the end makes it longer(some of characters repeat)
This commit is contained in:
parent
6b8428e262
commit
0f18463df0
1 changed files with 1 additions and 1 deletions
|
@ -338,7 +338,7 @@ class Command(BaseCommand):
|
||||||
#Shorten the ID if it's necessary. Pretty hacky
|
#Shorten the ID if it's necessary. Pretty hacky
|
||||||
#I _REALLY_ should make a nice function for it that can partition and shorten stuff
|
#I _REALLY_ should make a nice function for it that can partition and shorten stuff
|
||||||
space_left = cols - strwidth("[s] 100.00% " + status["name"] + " "*3) - 2
|
space_left = cols - strwidth("[s] 100.00% " + status["name"] + " "*3) - 2
|
||||||
if space_left - 8 >= len(torrent_id):
|
if space_left >= len(torrent_id):
|
||||||
#There's enough space, print it
|
#There's enough space, print it
|
||||||
s += " {!cyan!}%s" % torrent_id
|
s += " {!cyan!}%s" % torrent_id
|
||||||
else:
|
else:
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue