Skip to content
This repository has been archived by the owner on Jul 10, 2023. It is now read-only.

Commit

Permalink
[#90] Hotfix for interactive mode.
Browse files Browse the repository at this point in the history
  • Loading branch information
shunyi authored and shunyi committed Apr 17, 2016
1 parent 4a3ab43 commit 0c286da
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion zdict/tests/dictionaries/test_spanish.py
Expand Up @@ -6,7 +6,7 @@
from zdict.zdict import get_args


class TestSpansishDict:
class TestSpanishDict:
@classmethod
def setup_class(cls):
cls.dict = SpanishDict(get_args())
Expand Down
6 changes: 4 additions & 2 deletions zdict/zdict.py
Expand Up @@ -232,7 +232,9 @@ def normal_mode(args):
class MetaInteractivePrompt():
def __init__(self, args):
self.args = args
self.dicts = tuple(dictionary_map[d]() for d in self.args.dict)
self.dicts = tuple(
dictionary_map[d](self.args) for d in self.args.dict
)
self.dict_classes = tuple(dictionary_map[d] for d in self.args.dict)

if self.args.jobs == 0:
Expand Down Expand Up @@ -260,7 +262,7 @@ def prompt(self):
print(''.join(results))
else:
for dictionary_instance in self.dicts:
dictionary_instance.lookup(user_input, self.args)
dictionary_instance.lookup(user_input)
else:
return

Expand Down

0 comments on commit 0c286da

Please sign in to comment.