@@ -100,12 +100,6 @@ class PyMongo(object):
100
100
variable, or as an argument to the constructor or ``init_app``. See
101
101
:meth:`init_app` for more detail.
102
102
103
- .. versionchanged:: 2.0
104
-
105
- Flask-PyMongo no longer accepts many of the configuration variables
106
- it did in previous versions. You must now use a MongoDB URI to
107
- configure Flask-PyMongo.
108
-
109
103
"""
110
104
111
105
def __init__ (self , app = None , uri = None , * args , ** kwargs ):
@@ -118,12 +112,11 @@ def __init__(self, app=None, uri=None, *args, **kwargs):
118
112
def init_app (self , app , uri = None , * args , ** kwargs ):
119
113
"""Initialize this :class:`PyMongo` for use.
120
114
121
- Configure a :class:`~pymongo.mongo_client.MongoClient` or
122
- :class:`~pymongo.mongo_replica_set_client.MongoReplicaSetClient`
115
+ Configure a :class:`~pymongo.mongo_client.MongoClient`
123
116
in the following scenarios:
124
117
125
118
1. If ``uri`` is not ``None``, pass the ``uri`` and any positional
126
- or keyword arguments to MongoClient
119
+ or keyword arguments to :class:`~pymongo.mongo_client. MongoClient`
127
120
2. If ``uri`` is ``None``, and a Flask config variable named
128
121
``MONGO_URI`` exists, use that as the ``uri`` as above.
129
122
0 commit comments