diff --git a/pyicloud/services/photos.py b/pyicloud/services/photos.py index 30510ab..9df8314 100644 --- a/pyicloud/services/photos.py +++ b/pyicloud/services/photos.py @@ -173,6 +173,11 @@ class PhotosService(object): } for folder in self._fetch_folders(): + + # Skiping albums having null name, that can happen sometime + if "albumNameEnc" not in folder["fields"]: + continue + # TODO: Handle subfolders # pylint: disable=fixme if folder["recordName"] == "----Root-Folder----" or ( folder["fields"].get("isDeleted")