Show More
@@ -507,12 +507,10 b' class Application(SingletonConfigurable):' | |||||
507 | """ |
|
507 | """ | |
508 | pyloader = PyFileConfigLoader(basefilename+'.py', path=path, log=log) |
|
508 | pyloader = PyFileConfigLoader(basefilename+'.py', path=path, log=log) | |
509 | jsonloader = JSONFileConfigLoader(basefilename+'.json', path=path, log=log) |
|
509 | jsonloader = JSONFileConfigLoader(basefilename+'.json', path=path, log=log) | |
510 | config_found = False |
|
|||
511 | config = None |
|
510 | config = None | |
512 | for loader in [pyloader, jsonloader]: |
|
511 | for loader in [pyloader, jsonloader]: | |
513 | try: |
|
512 | try: | |
514 | config = loader.load_config() |
|
513 | config = loader.load_config() | |
515 | config_found = True |
|
|||
516 | except ConfigFileNotFound: |
|
514 | except ConfigFileNotFound: | |
517 | pass |
|
515 | pass | |
518 | except Exception: |
|
516 | except Exception: | |
@@ -529,8 +527,6 b' class Application(SingletonConfigurable):' | |||||
529 | if config: |
|
527 | if config: | |
530 | yield config |
|
528 | yield config | |
531 |
|
529 | |||
532 | if not config_found: |
|
|||
533 | raise ConfigFileNotFound('Neither .json, nor .py config file found.') |
|
|||
534 | raise StopIteration |
|
530 | raise StopIteration | |
535 |
|
531 | |||
536 |
|
532 |
General Comments 0
You need to be logged in to leave comments.
Login now