Commit f594fe1f authored by Julien Muchembled's avatar Julien Muchembled

Fix read of own IP from cache

In SQLite, a string that only contains '0' chars evaluates to False.
parent 26f11428
...@@ -201,7 +201,7 @@ class Cache(object): ...@@ -201,7 +201,7 @@ class Cache(object):
@property @property
def my_address(self): def my_address(self):
for x, in self._db.execute("SELECT address FROM peer WHERE NOT prefix"): for x, in self._db.execute("SELECT address FROM peer WHERE prefix=''"):
return x return x
@my_address.setter @my_address.setter
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment