appease the linter

This commit is contained in:
Christopher Teutsch 2019-05-04 19:30:25 +02:00
parent 35749eb0bd
commit 8ff527b88a
Signed by: iwonder
GPG Key ID: 0EE33D788D50130D

View File

@ -52,6 +52,7 @@ parser.add_argument(
parser.add_argument(
'--cache-dir',
dest='cache_dir',
type=str,
help='Override the default cache directory with your own path'
)
exc_group = parser.add_mutually_exclusive_group()
@ -78,13 +79,13 @@ vals_group.add_argument(
def _process_stdin(argv: str, res: utils.CurrencyResult) -> None:
argv=argv.split()
argv = argv.split()
try:
if argv[0] in ['q', 'exit', 'quit']:
sys.exit()
elif argv[0] in ['date', 'd']:
print(res.date)
elif len(argv[0])==3 or len(argv[1])==3:
elif len(argv[0]) == 3 or len(argv[1]) == 3:
# more than 3 letter abbreviations are invalid
if is_float(argv[0]):
# amount first -> convert to currency in argv[1]