diff options
author | Santo Cariotti <sancn@live.com> | 2017-07-29 20:27:47 +0200 |
---|---|---|
committer | Santo Cariotti <sancn@live.com> | 2017-07-29 20:27:47 +0200 |
commit | efda27de3207e3471e2620d72487cdfcea8dd55e (patch) | |
tree | 7171903caa5f984fc674182f8454af684213527f /lib/commands.py | |
parent | 46d56ebe56a99c156bdade1d92f5c1fa41269a41 (diff) |
deleted COLORS class for COLORS constants
Diffstat (limited to 'lib/commands.py')
-rw-r--r-- | lib/commands.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/commands.py b/lib/commands.py index e8cb171..c727f90 100644 --- a/lib/commands.py +++ b/lib/commands.py @@ -1,4 +1,4 @@ -from classes import PersonalError, r, clear, Colors +from classes import PersonalError, r, clear, RED, GREY from listcommands import ListCommands from config import config as co @@ -17,7 +17,7 @@ class Commands(object): raise PersonalError('lunghezza maggiore del consetito. Max 10') if len(cmd) > ListCommands.info['set'][1]: - raise PersonalError(Colors.grey + 'set user' + Colors.red + ' accetta 1 parametro') + raise PersonalError(GREY + 'set user' + RED + ' accetta 1 parametro') self.user = cmd[2] @@ -35,7 +35,7 @@ class Commands(object): elif what == 'get': try: if len(cmd) > ListCommands.info['get'][1]: - raise PersonalError(Colors.grey + 'get ' + Colors.red + 'accetta 2 parametri') + raise PersonalError(GREY + 'get ' + RED + 'accetta 2 parametri') if cmd[1] == 'i': #if first word after get is 'i', there is an info if cmd[2] == 'user': @@ -93,7 +93,7 @@ class Commands(object): elif what == 'del': try: if len(cmd) > ListCommands.info['del'][1]: - raise PersonalError(Colors.grey + 'del ' + Colors.red + 'accetta 1 parametro') + raise PersonalError(GREY + 'del ' + RED + 'accetta 1 parametro') if r.get('idTODO') is None or r.get('idTODO') == 0: #idTODO is null or 0 print('nessun todo in lista: goditi una Stout') |