Fix crash when no proxy is configured.
authorMichael Tremer <michael.tremer@ipfire.org>
Sun, 8 Jun 2014 14:21:17 +0000 (16:21 +0200)
committerMichael Tremer <michael.tremer@ipfire.org>
Sun, 8 Jun 2014 14:21:17 +0000 (16:21 +0200)
ddns/system.py

index 400d38f..1e1fa0b 100644 (file)
@@ -48,7 +48,7 @@ class DDNSSystem(object):
                proxy = self.core.settings.get("proxy")
 
                # Strip http:// at the beginning.
                proxy = self.core.settings.get("proxy")
 
                # Strip http:// at the beginning.
-               if proxy.startswith("http://"):
+               if proxy and proxy.startswith("http://"):
                        proxy = proxy[7:]
 
                return proxy
                        proxy = proxy[7:]
 
                return proxy