Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

display shared albums #2

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion custom_components/immich/hub.py
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ async def list_all_albums(self) -> list[dict]:
"""List all albums."""
try:
async with aiohttp.ClientSession() as session:
url = urljoin(self.host, "/api/album")
url = urljoin(self.host, "/api/album?shared=true")
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unfortunately ?shared=true means the API will only return the shared albums, so I can't merge this as-is 😕

Aren't shared albums included in the results by default?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

no, i have an account who only has shared albums, in that case, the dropdown doesnt even render.

headers = {"Accept": "application/json", _HEADER_API_KEY: self.api_key}

async with session.get(url=url, headers=headers) as response:
Expand Down