Fix help bug for export-rattail
command
can't assume we have a config object
This commit is contained in:
parent
559d14eb21
commit
4323fde854
|
@ -263,8 +263,12 @@ class ExportRattail(ImportSubcommand):
|
||||||
default_dbkey = 'host'
|
default_dbkey = 'host'
|
||||||
|
|
||||||
def get_handler_factory(self, **kwargs):
|
def get_handler_factory(self, **kwargs):
|
||||||
spec = self.config.get('rattail.exporting', 'rattail.handler',
|
if self.config:
|
||||||
default=self.default_handler_spec)
|
spec = self.config.get('rattail.exporting', 'rattail.handler',
|
||||||
|
default=self.default_handler_spec)
|
||||||
|
else:
|
||||||
|
# just use default, for sake of cmd line help
|
||||||
|
spec = self.default_handler_spec
|
||||||
return load_object(spec)
|
return load_object(spec)
|
||||||
|
|
||||||
def add_parser_args(self, parser):
|
def add_parser_args(self, parser):
|
||||||
|
|
Loading…
Reference in a new issue