From 02a675d9ea74db8c70414d84ce9fc444f5c26964 Mon Sep 17 00:00:00 2001 From: Alexandre Dulaunoy Date: Sun, 22 Aug 2021 23:37:05 +0200 Subject: [PATCH] fix: [api] typo fixed --- bin/server.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/bin/server.py b/bin/server.py index 2239cb0..0861082 100644 --- a/bin/server.py +++ b/bin/server.py @@ -140,11 +140,10 @@ class lookup(Resource): h['ProductCode'] = rdb.hgetall("h-ProductCode:{}".format(h['ProductCode'])) if rdb.exists("p:{}".format(k)): parents = [] - for parent in rdb.smembers("p:{}".format(sha1)): + for parent in rdb.smembers("p:{}".format(k)): parent_details = rdb.hgetall("h:{}".format(parent)) parents.append(parent_details) h['parents'] = parents - return h @api.route('/info')