Skip to content

Commit f669d27

Browse files
authored
Merge pull request #51 from clobrano/fix-edit-handler
Do not use old Configuration object
2 parents 6f6a217 + ca75c95 commit f669d27

File tree

1 file changed

+2
-9
lines changed

1 file changed

+2
-9
lines changed

src/cli.py

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -34,14 +34,7 @@
3434
import handlers
3535
from app import guess_task_id_from_string, do_report
3636
from log import RAFFAELLO
37-
from configuration import get_configuration, CONFIG_FILE_NAME
38-
39-
40-
def _p(msg):
41-
"""Colorize message"""
42-
if msg and get_configuration()["color"] and RAFFAELLO:
43-
return RAFFAELLO.paint(str(msg))
44-
return msg
37+
from configuration import get_configuration, get_task_file_path, CONFIG_FILE_NAME
4538

4639

4740
def main():
@@ -60,7 +53,7 @@ def main():
6053
)
6154

6255
elif args["edit"]:
63-
is_ok, msg = handlers.edit_file_handler(Configuration().task_fullpath)
56+
is_ok, msg = handlers.edit_file_handler(get_task_file_path())
6457
print(msg)
6558
if not is_ok:
6659
return 1

0 commit comments

Comments
 (0)