From 182971e61b582d784025643a22f7b8de40fa2c31 Mon Sep 17 00:00:00 2001 From: Santo Cariotti Date: Tue, 22 Aug 2017 11:23:28 +0200 Subject: fixed 'get todo' --- lib/app.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'lib/app.py') diff --git a/lib/app.py b/lib/app.py index 1a74485..c3ec9a7 100644 --- a/lib/app.py +++ b/lib/app.py @@ -2,6 +2,7 @@ from classes import r, clear, YELLOW, BLACK, GREY from commands import Commands from listcommands import ListCommands import os.path +from config import config class Stout(Commands): @@ -22,7 +23,7 @@ class Stout(Commands): if users exists, return username, else return an empty string """ try: - with open('/tmp/stout', 'rb') as fin: + with open(config['path'], 'rb') as fin: user = fin.readline() if user == '': @@ -69,8 +70,8 @@ if __name__ == '__main__': app = Stout() cmd = '' - if not os.path.isfile('/tmp/stout'): - open('/tmp/stout', 'wb').close() + if not os.path.isfile(config['path']): + open(config['path'], 'wb').close() while cmd != 'quit': try: -- cgit v1.2.3-18-g5258