From 800c2167ca332e7b59072a1c928cbb9ba996f369 Mon Sep 17 00:00:00 2001 From: Kali Kaneko Date: Thu, 12 May 2016 18:59:24 -0400 Subject: [style] improve readability --- src/leap/mx/couchdbhelper.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/leap/mx/couchdbhelper.py b/src/leap/mx/couchdbhelper.py index f17466d..50275ca 100644 --- a/src/leap/mx/couchdbhelper.py +++ b/src/leap/mx/couchdbhelper.py @@ -100,7 +100,8 @@ class ConnectedCouchDB(client.CouchDB): pubkey = None if result["rows"]: doc = result["rows"][0]["doc"] - if "enabled" not in doc or doc["enabled"]: + user_enabled = doc.get('enabled', True) + if user_enabled: uuid = doc["user_id"] if "keys" in doc: pubkey = doc["keys"]["pgp"] -- cgit v1.2.3