Merge branch 'master' of bitbucket.org:panleicim/appointment_tool

This commit is contained in:
2023-12-30 14:24:32 +01:00
+3 -1
View File
@@ -78,7 +78,9 @@ class MongoDbManager:
try: try:
collection_to_use = self.db[CONTACT_LIST_TO_BOOK] collection_to_use = self.db[CONTACT_LIST_TO_BOOK]
for contact in contact_list: for contact in contact_list:
collection_to_use.insert_one(contact.to_firestore_dict()) # collection_to_use.insert_one(contact.to_firestore_dict())
collection_to_use.replace_one(filter={'_id': contact.mail, }, replacement=contact.to_firestore_dict(),
upsert=True)
except Exception as Error: except Exception as Error:
self.logger.info(Error) self.logger.info(Error)