def get_storage_with_collection()

in ees_sharepoint/local_storage.py [0:0]


    def get_storage_with_collection(self, collection):
        """Returns a dictionary containing the locally stored IDs of files fetched from SharePoint
            :param collection: The SharePoint server collection which is currently being fetched
        """
        storage_with_collection = {"global_keys": {}, "delete_keys": {}}
        ids_collection = self.load_storage()
        storage_with_collection["delete_keys"] = copy.deepcopy(
            ids_collection.get("global_keys")
        )
        if not ids_collection["global_keys"].get(collection):
            ids_collection["global_keys"][collection] = {
                "sites": {},
                "lists": {},
                "list_items": {},
                "drive_items": {},
            }
        storage_with_collection["global_keys"][collection] = copy.deepcopy(
            ids_collection["global_keys"][collection]
        )

        return storage_with_collection