summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorthelamer <ryankuba@gmail.com>2019-06-10 05:50:06 -0700
committerCalum Lind <calumlind+deluge@gmail.com>2019-06-11 12:35:04 +0100
commita34543100c5ff9f32d590cb3d84f26080fc80925 (patch)
tree727355b53b49b1670358cdd7c478933e14c5caef
parentb8b044f4515264507416cf06307c4d357b70d1a5 (diff)
downloaddeluge-a34543100c5ff9f32d590cb3d84f26080fc80925.tar.gz
deluge-a34543100c5ff9f32d590cb3d84f26080fc80925.tar.bz2
deluge-a34543100c5ff9f32d590cb3d84f26080fc80925.zip
[Web] Fix peers tab failing to set flag location
The request.country returns bytes not a string so decode.
-rw-r--r--CHANGELOG.md10
-rw-r--r--deluge/ui/web/server.py3
2 files changed, 10 insertions, 3 deletions
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 64d8e718f..6fcfc2b36 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,5 +1,11 @@
# Changelog
+## 2.0.3 (WiP)
+
+### Web UI
+
+- Fix TypeError in Peers Tab setting country flag.
+
## 2.0.2 (2019-06-08)
### Packaging
@@ -47,7 +53,7 @@
- Add Option To Specify Outgoing Connection Interface.
- Fix potential for host_id collision when creating hostlist entries.
-### GtkUI
+### Gtk UI
- Ported to GTK3 (3rd-party plugins will need updated).
- Allow changing ownership of torrents.
@@ -62,7 +68,7 @@
- Top: Ctrl+Alt+Shift+Up
- Bottom: Ctrl+Alt+Shift+Down
-### WebUI
+### Web UI
- Server (deluge-web) now daemonizes by default, use '-d' or '--do-not-daemonize' to disable.
- Fixed the '--base' option to work for regular use, not just with reverse proxies.
diff --git a/deluge/ui/web/server.py b/deluge/ui/web/server.py
index c8f901a5a..3dceaf6ba 100644
--- a/deluge/ui/web/server.py
+++ b/deluge/ui/web/server.py
@@ -202,7 +202,8 @@ class Flag(resource.Resource):
return self
def render(self, request):
- path = ('ui', 'data', 'pixmaps', 'flags', request.country.lower() + '.png')
+ flag = request.country.decode('utf-8').lower() + '.png'
+ path = ('ui', 'data', 'pixmaps', 'flags', flag)
filename = common.resource_filename('deluge', os.path.join(*path))
if os.path.exists(filename):
request.setHeader(