From 3de1bc419815e5b238ed1a3579b3656016dab4da Mon Sep 17 00:00:00 2001 From: Cyrille L Date: Tue, 14 Mar 2023 15:34:43 +0100 Subject: [PATCH] wip fixes (get values from db for abbr and link) --- src/var/lib/tyto/program/logs.py | 1 + src/var/lib/tyto/program/wip.py | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/var/lib/tyto/program/logs.py b/src/var/lib/tyto/program/logs.py index 4344680..1180267 100644 --- a/src/var/lib/tyto/program/logs.py +++ b/src/var/lib/tyto/program/logs.py @@ -71,4 +71,5 @@ def out(nbr, value, out): msg = logs[nbr] print(msg) + if int(nbr) == 21: nbr = 0 if out: sys.exit(int(nbr)) diff --git a/src/var/lib/tyto/program/wip.py b/src/var/lib/tyto/program/wip.py index c488234..2f55292 100644 --- a/src/var/lib/tyto/program/wip.py +++ b/src/var/lib/tyto/program/wip.py @@ -268,7 +268,7 @@ def wip_links(): if db.uniq_links > 0: for i in range(1, db.uniq_links + 1): - link = 'link_%s'%i + link = 'db.link_%s'%i post_bottom = post_bottom.replace(eval(link)[0]+'+', eval(link)[1]%('_blank') ) @@ -286,7 +286,7 @@ def wip_abbrs(): global post_bottom for i in range(1, db.uniq_abbrs + 1): - abbr = 'abbr_%s'%i + abbr = 'db.abbr_%s'%i post_bottom = post_bottom.replace(eval(abbr)[0], eval(abbr)[1] )