applications: Define std* in the proper class

This would make weboob-debug unusable, for example.
This commit is contained in:
Laurent Bachelier 2014-09-18 12:49:26 +02:00
commit e9c047ce93
2 changed files with 4 additions and 4 deletions

View file

@ -100,6 +100,10 @@ class BaseApplication(object):
# Copyright
COPYRIGHT = None
stdin = sys.stdin
stdout = sys.stdout
stderr = sys.stderr
# ------ Abstract methods --------------------------------------
def create_weboob(self):
return Weboob()

View file

@ -73,10 +73,6 @@ class ConsoleApplication(BaseApplication):
BOLD = ''
NC = '' # no color
stdin = sys.stdin
stdout = sys.stdout
stderr = sys.stderr
def __init__(self, option_parser=None):
BaseApplication.__init__(self, option_parser)
self.weboob.callbacks['login'] = self.login_cb