From 7c31b86f800eab4b07f8d7109f1ec7ce43c52a5c Mon Sep 17 00:00:00 2001 From: Mauro Scomparin Date: Mon, 16 Sep 2019 22:48:52 +0200 Subject: [PATCH] forse --- money/money.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/money/money.py b/money/money.py index 0786830..a2f3553 100755 --- a/money/money.py +++ b/money/money.py @@ -216,7 +216,8 @@ def latest_movements(): write_latest_movements(data_file, resulting_config) def mov_filter(movs, filter): - return list(filter(lambda m: re.match(filter, m[DESCRIPTION_FIELD_NAME]))) + p = re.compile(filter) + return [m for m in movs if p.match(m[DESCRIPTION_FIELD_NAME])] def filter_regex_movements(data_file, conf, filter): movements = load_file(data_file) -- 2.25.1