Skip to content

Commit

Permalink
Fixed bug, but no pytest to check yet
Browse files Browse the repository at this point in the history
  • Loading branch information
MarekSuchanek committed Jul 11, 2017
1 parent 1dc4ac5 commit 9eba994
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
3 changes: 2 additions & 1 deletion repocribro/manage.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,12 @@ def run():
.. todo:: allow extension add options & commands,
separate create and run part of function
command for checking config
"""
manager = flask_script.Manager(create_app)
manager.add_option('-c', '--config', dest='cfg_files',
required=False, action='append',
default='DEFAULT')
default=['DEFAULT'])
manager.add_option('-v', '--version', action='version',
version='{} v{}'.format(PROG_NAME, VERSION))

Expand Down
4 changes: 2 additions & 2 deletions repocribro/repocribro.py
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ def __init__(self):
self.container = DI_Container()


def create_app(cfg_files='DEFAULT'):
def create_app(cfg_files=['DEFAULT']):
"""Factory for making the web Flask application
:param cfg_files: Single or more config file(s)
Expand All @@ -93,7 +93,7 @@ def create_app(cfg_files='DEFAULT'):
ext_master = ExtensionsMaster(app=app, db=db)
app.container.set_singleton('ext_master', ext_master)

if cfg_files == 'DEFAULT':
if cfg_files == ['DEFAULT']:
cfg_files = os.environ.get('REPOCRIBRO_CONFIG_FILE',
DEFAULT_CONFIG_FILES)

Expand Down

0 comments on commit 9eba994

Please sign in to comment.