From 976824ad99aa4f5912c26bf01b1491af7eab56f2 Mon Sep 17 00:00:00 2001 From: Damien Churchill Date: Wed, 27 Jan 2010 20:23:15 +0000 Subject: [PATCH] revert to the default theme if the selected themes stylesheet is missing --- deluge/ui/web/server.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/deluge/ui/web/server.py b/deluge/ui/web/server.py index 3af8d9485..2e6d33ca8 100644 --- a/deluge/ui/web/server.py +++ b/deluge/ui/web/server.py @@ -400,8 +400,11 @@ class TopLevel(resource.Resource): self.putChild("tracker", Tracker()) theme = component.get("DelugeWeb").config["theme"] + if not os.path.isfile(rpath("css", "xtheme-%s.css" % theme)): + theme = CONFIG_DEFAULTS.get("theme") self.__stylesheets.insert(1, "/css/xtheme-%s.css" % theme) + @property def scripts(self): return self.__scripts