Last active
December 22, 2015 15:59
-
-
Save bulv1ne/6496562 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# self.app can be None | |
# self.app.config.get('DATABASE') can be None | |
try: | |
db = self.app.config['DATABASE'] | |
logger.debug('Using database "{db}"'.format(db=db)) | |
except: | |
db = 'test' | |
logger.warning('DATABASE setting not set, using database "test"') |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment