Permalink
Browse files

Merge pull request #56 from dedan/master

don't delete the database specific config entries from the app
  • Loading branch information...
coleifer committed Dec 21, 2012
2 parents 1487bbf + 555a9de commit 50809072330988279cd67c6564975650a2ea7476
Showing with 2 additions and 2 deletions.
  1. +2 −2 flask_peewee/db.py
View
@@ -17,8 +17,8 @@ def __init__(self, app):
def load_database(self):
self.database_config = self.app.config['DATABASE']
try:
- self.database_name = self.database_config.pop('name')
- self.database_engine = self.database_config.pop('engine')
+ self.database_name = self.database_config.get('name')
+ self.database_engine = self.database_config.get('engine')
except KeyError:
raise ImproperlyConfigured('Please specify a "name" and "engine" for your database')

2 comments on commit 5080907

@changpingc

This comment has been minimized.

Show comment Hide comment
@changpingc

changpingc Jan 2, 2013

This patch is breaking my code. :( It should be pop because these parameters (name and engine) are not supposed to be passed onto sqlite3.connect in my case. I'm not sure with other dbs though. Hope this get fixed.

This patch is breaking my code. :( It should be pop because these parameters (name and engine) are not supposed to be passed onto sqlite3.connect in my case. I'm not sure with other dbs though. Hope this get fixed.

@coleifer

This comment has been minimized.

Show comment Hide comment
@coleifer

coleifer Jan 4, 2013

Owner

Yes, thank you for mentioning this -- a ticket was opened by someone else and i have reverted this merge. Master should be back to working again.

Owner

coleifer replied Jan 4, 2013

Yes, thank you for mentioning this -- a ticket was opened by someone else and i have reverted this merge. Master should be back to working again.

Please sign in to comment.