fix(context): move where args are set to context so log/etc isnt overwritten
parent
941efd353a
commit
97d9f62803
|
@ -8,6 +8,9 @@ import configparser
|
|||
class Context:
|
||||
|
||||
def __init__(self, db, logger, args):
|
||||
for key, value in vars(args).items():
|
||||
setattr(self, key, value)
|
||||
|
||||
self.db = db
|
||||
self.log = logger
|
||||
self.log.debug = logging.debug
|
||||
|
@ -16,6 +19,3 @@ class Context:
|
|||
|
||||
self.conf = configparser.ConfigParser()
|
||||
self.conf.read(os.path.expanduser('~/.cme/cme.conf'))
|
||||
|
||||
for key, value in vars(args).items():
|
||||
setattr(self, key, value)
|
||||
|
|
Loading…
Reference in New Issue