kopia lustrzana https://github.com/ihabunek/toot
Fix version detection
Version check failed when the server sent something other than a number as a version as happened on development version of the gotosocial server.pull/298/head
rodzic
0a6543d355
commit
4f9391f015
|
@ -336,7 +336,8 @@ class TUI(urwid.Frame):
|
|||
# this works for Mastodon and Pleroma version strings
|
||||
# Mastodon versions < 4 do not have translation service
|
||||
# Revisit this logic if Pleroma implements translation
|
||||
self.can_translate = int(instance["version"][0]) > 3
|
||||
ch = instance["version"][0]
|
||||
self.can_translate = int(ch) > 3 if ch.isnumeric() else False
|
||||
|
||||
return self.run_in_thread(_load_instance, done_callback=_done)
|
||||
|
||||
|
|
Ładowanie…
Reference in New Issue