-
Notifications
You must be signed in to change notification settings - Fork 19
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
Links to files break after moving or renaming files #1527
Comments
Hey @TheNomad11, thanks for your report. I'm able to reproduce your bug. It seems like the server returns an outdated reference object from the cache. We probably need to take care that the the reference cache for files gets invalidated when they get moved or copied. Cc @juliusknorr as you worked on this in the past. |
Which URL format is being used? Wondering with the internal URL we should not see any change in the URL with the move and I'd expect that with any other we should still have the file id as identifier, so maybe that is rather a but in the extraction logic to get the file metadata for the specific link |
Exactly, the URL does not change. But the reference response contains the file metadata which contains the file name (which changed) - and apparently this is passed to the viewer for opening the file. |
All right, in that case it should be just a matter if invalidating the cache in https://github.com/nextcloud/server/blob/dae7c159f728a90ffa53247d6e033abdae5d2bd6/lib/private/Collaboration/Reference/File/FileReferenceEventListener.php#L30 |
Describe the bug
Links to files break after moving or renaming files
To Reproduce
Steps to reproduce the behavior:
Expected behavior
The Pdf link loads, as these links are permanant within Nextcloud. They still work after moving and renaming
Server details:
Client details:
The text was updated successfully, but these errors were encountered: