From d6fe136421aac67d43f7abe2953f916c4c64ac76 Mon Sep 17 00:00:00 2001 From: Alexandre Dulaunoy Date: Thu, 9 Sep 2021 07:34:37 +0200 Subject: [PATCH] chg: [api/info] now return the default stats from the new importer TODO: add the diff with additional sources and key numbers --- bin/server.py | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/bin/server.py b/bin/server.py index c470c52..5d93abb 100644 --- a/bin/server.py +++ b/bin/server.py @@ -190,13 +190,10 @@ class info(Resource): def get(self): info = {} info['nsrl-version'] = rdb.get('nsrl-version') - info['nsrl-NSRL-items'] = rdb.get('stat:import') - info['nsrl-NSRL-Legacy-items'] = rdb.get('stat:NSRLLegacy') - info['nsrl-Android-items'] = rdb.get('stat:NSRLAndroid') - info['nsrl-iOS-items'] = rdb.get('stat:NSRLiOS') - info['nsrl-NSRLMfg'] = str(rdb.scard('s:MfgCode')) - info['nsrl-NSRLOS'] = str(rdb.scard('s:OpSystemCode')) - info['nsrl-NSRLProd'] = str(rdb.scard('s:ProductCode')) + info['stat:nsrl_modern_rds'] = rdb.get('stat:nsrl_modern_rds') + info['stat:nsrl_legacy'] = rdb.get('stat:nsrl_legacy') + info['stat:nsrl_ios'] = rdb.get('stat:nsrl_ios') + info['stat:nsrl_android'] = rdb.get('stat:nsrl_android') info['hashlookup-version'] = version return info