Skip to content

Cannot read image info in public album share #1615

@Gobbel2000

Description

@Gobbel2000

Describe the bug

After upgrading memories to 7.8, no metadata is shown when viewing an album through a public share. The images themselves are still shown.

In particular, the request with path
/apps/memories/api/image/info/<IMG_ID>?token=<SHARE_TOKEN>&albums=<SHARE_TOKEN>
fails with status 500 and the response message The requested share does not exist anymore.

Steps To Reproduce

  1. Create any album with some images in it.
  2. Share the album by creating a public link.
  3. Open this link in a private browser window to access the public share.
  4. Try viewing the info of an image. The info sidebar says "Failed to load metadata" and the browser console shows the failed request above.

Platform

- OS: Linux
- Browser: Firefox
- Memories Version: 7.8.2
- Nextcloud Version: 32.0.5
- PHP Version: 8.4.16

Screenshots

No response

Additional context

Trace given in Nextcloud logs:

[
  {
    "file": "/var/www/nextcloud/apps/memories/lib/Db/FsManager.php",
    "line": 320,
    "function": "getShareByToken",
    "class": "OC\\Share20\\Manager",
    "type": "->"
  },
  {
    "file": "/var/www/nextcloud/apps/memories/lib/Db/FsManager.php",
    "line": 346,
    "function": "getShareObject",
    "class": "OCA\\Memories\\Db\\FsManager",
    "type": "->"
  },
  {
    "file": "/var/www/nextcloud/apps/memories/lib/Controller/ImageController.php",
    "line": 260,
    "function": "getShareNode",
    "class": "OCA\\Memories\\Db\\FsManager",
    "type": "->"
  },
  {
    "file": "/var/www/nextcloud/apps/memories/lib/UtilController.php",
    "line": 20,
    "function": "{closure:OCA\\Memories\\Controller\\ImageController::info():198}",
    "class": "OCA\\Memories\\Controller\\ImageController",
    "type": "->"
  },
  {
    "file": "/var/www/nextcloud/apps/memories/lib/Controller/ImageController.php",
    "line": 198,
    "function": "guardEx",
    "class": "OCA\\Memories\\Util",
    "type": "::"
  },
  {
    "file": "/var/www/nextcloud/lib/private/AppFramework/Http/Dispatcher.php",
    "line": 204,
    "function": "info",
    "class": "OCA\\Memories\\Controller\\ImageController",
    "type": "->"
  },
  {
    "file": "/var/www/nextcloud/lib/private/AppFramework/Http/Dispatcher.php",
    "line": 118,
    "function": "executeController",
    "class": "OC\\AppFramework\\Http\\Dispatcher",
    "type": "->"
  },
  {
    "file": "/var/www/nextcloud/lib/private/AppFramework/App.php",
    "line": 153,
    "function": "dispatch",
    "class": "OC\\AppFramework\\Http\\Dispatcher",
    "type": "->"
  },
  {
    "file": "/var/www/nextcloud/lib/private/Route/Router.php",
    "line": 321,
    "function": "main",
    "class": "OC\\AppFramework\\App",
    "type": "::"
  },
  {
    "file": "/var/www/nextcloud/lib/base.php",
    "line": 1061,
    "function": "match",
    "class": "OC\\Route\\Router",
    "type": "->"
  },
  {
    "file": "/var/www/nextcloud/index.php",
    "line": 25,
    "function": "handleRequest",
    "class": "OC",
    "type": "::"
  }
]

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions