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

fix(web): unable to download live photo as anonymous user #16455

Merged
merged 1 commit into from
Mar 1, 2025

Conversation

Mikayex
Copy link
Contributor

@Mikayex Mikayex commented Mar 1, 2025

Description

As described in the bug report, get(preferences) returns undefined if the user is not logged in (from a shared album/image link for example). As such, it is impossible to download a live photo in this case: the downloadFile function throws an error instead.

Fixes #15836

(Note that I'm a C++/desktop developer, so I'm in unknown territory here 😅 But the change should be simple enough...)

How Has This Been Tested?

Manually tested in these conditions:

  • Download live photo from logged in user with includeEmbeddedVideos option enabled
  • Download live photo from logged in user with includeEmbeddedVideos option disabled
  • Download live photo from shared album link from a private browser session (anonymous user)

Checklist:

  • I have performed a self-review of my own code
  • I have made corresponding changes to the documentation if applicable
  • I have no unrelated changes in the PR.
  • I have confirmed that any new dependencies are strictly necessary.
  • I have written tests for new code (if applicable)
  • I have followed naming conventions/patterns in the surrounding code
  • All code in src/services uses repositories implementations for database calls, filesystem operations, etc.
  • All code in src/repositories/ is pretty basic/simple and does not have any immich specific logic (that belongs in src/services)

Copy link
Contributor

@alextran1502 alextran1502 left a comment

Choose a reason for hiding this comment

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

Thanks much! C++ dev is a different breed 😝

@alextran1502 alextran1502 merged commit 2510684 into immich-app:main Mar 1, 2025
39 of 40 checks passed
knechtandreas added a commit to knechtandreas/immich that referenced this pull request Mar 2, 2025
…n-grid

* main: (22 commits)
  feat: add album keyboard shortcuts (immich-app#16442)
  fix(web): Default to context search on web (immich-app#16485)
  fix(mobile): Updated formatting of server address in networking (immich-app#16483)
  chore(mobile): rename log enum to lowercase (immich-app#16476)
  fix(web): Open huggingface.co link on settings page in new tab (immich-app#16470)
  fix(web): fix typos (immich-app#16466)
  fix(web): Fixed people list overflowing in advanced search (immich-app#16457)
  fix(web): unable to download live photo as anonymous user (immich-app#16455)
  fix(mobile): fix typos (immich-app#16456)
  chore: add 'not duplicate' checkbox to issue template (immich-app#16462)
  chore(mobile): post release task (immich-app#16437)
  feat(server): Shortened asset ID in storage template (immich-app#16433)
  chore: version v1.128.0
  fix: memories off by one (immich-app#16434)
  fix(server): stringify error log parameter to ensure correct overload (immich-app#16422)
  fix: duplicate memories (immich-app#16432)
  chore(server): trash e2e cleanup (immich-app#16423)
  fix(server): include deleted assets if searching offline assets (immich-app#16417)
  fix: user delete sync query sort by id (immich-app#16420)
  fix(mobile): background backup failing due to store (immich-app#16418)
  ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Web: Unable to download a live photo from an album link
3 participants