summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohan Lundberg <lundberg@sunet.se>2022-12-16 15:15:51 +0100
committerIvan Kanakarakis <ivan.kanak@gmail.com>2022-12-23 14:37:49 +0200
commit803eb892542a721fe6c494b91c3924a31ec6e403 (patch)
treefc15c8946b6d360618b8e3ef0bb44494db50691d
parent27a39d20a28f6c3e3e1a91e482e934dc7c0aa6d6 (diff)
downloadpysaml2-803eb892542a721fe6c494b91c3924a31ec6e403.tar.gz
collection.remove has been removed in pymongo >=4
-rw-r--r--src/saml2/mongo_store.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/saml2/mongo_store.py b/src/saml2/mongo_store.py
index 4c0599e9..451442fb 100644
--- a/src/saml2/mongo_store.py
+++ b/src/saml2/mongo_store.py
@@ -99,7 +99,7 @@ class SessionStorageMDB:
logger.debug("remove authn about: %s", name_id)
key = sha1(code_binary(name_id)).hexdigest()
for item in self.assertion.find({"name_id_key": key}):
- self.assertion.remove(item["_id"])
+ self.assertion.delete_one(item["_id"])
def get_authn_statements(self, name_id, session_index=None, requested_context=None):
"""