From: Michael Tremer Date: Wed, 28 Oct 2020 09:52:36 +0000 (+0000) Subject: location: Fix Python syntax error in verify() X-Git-Tag: 0.9.5~94 X-Git-Url: http://git.ipfire.org/?p=location%2Flibloc.git;a=commitdiff_plain;h=e99a72265c1ba2194b61663eda7e9f14e0083016 location: Fix Python syntax error in verify() The database is now being opened before the requested method is called and handle_verify() wasn't updated. Signed-off-by: Michael Tremer --- diff --git a/src/python/location.in b/src/python/location.in index 44ad726..b5e5758 100644 --- a/src/python/location.in +++ b/src/python/location.in @@ -453,13 +453,7 @@ class CLI(object): return 0 - def handle_verify(self, ns): - try: - db = location.Database(ns.database) - except FileNotFoundError as e: - log.error("%s: %s" % (ns.database, e)) - return 127 - + def handle_verify(self, db, ns): # Verify the database with open(ns.public_key, "r") as f: if not db.verify(f):