Skip to content

Commit 3fc629e

Browse files
committed
Correct mistaken use of conn_settings over conn
This caused a problem when the settings were provided as uppercase but then attempted access using a lowercase key.
1 parent fb8fb46 commit 3fc629e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

flask_mongoengine/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ def _create_connection(conn_settings):
8888

8989
# Handle uri style connections
9090
if "://" in conn.get('host', ''):
91-
uri_dict = uri_parser.parse_uri(conn_settings['host'])
91+
uri_dict = uri_parser.parse_uri(conn['host'])
9292
conn['db'] = uri_dict['database']
9393

9494
return mongoengine.connect(conn.pop('db', 'test'), **conn)

0 commit comments

Comments
 (0)