Skip to content

Commit d1ac1ee

Browse files
committed
remove BSONObjectIDConverter registration helper
it's a well-documented one-liner to register this manually, so don't add a different one-liner way to do it.
1 parent 9180b89 commit d1ac1ee

File tree

1 file changed

+0
-11
lines changed

1 file changed

+0
-11
lines changed

flask_pymongo/__init__.py

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -160,17 +160,6 @@ def init_app(self, app, uri=None, *args, **kwargs):
160160
self.cx = MongoClient(*args, **kwargs)
161161
self.db = self.cx[database_name]
162162

163-
self.register_bson_object_id_converter(app)
164-
165-
def register_bson_object_id_converter(self, app):
166-
"""Register :class:`BSONObjectIdConverter` with the ``app``.
167-
168-
This is called automatically by :meth:`init_app`, so in most cases
169-
you will not need to call this directly.
170-
171-
.. versionadded:: 2.0
172-
173-
"""
174163
app.url_map.converters["ObjectId"] = BSONObjectIdConverter
175164

176165
# view helpers

0 commit comments

Comments
 (0)