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

Allow force unlock of automated client locks #391

Merged
merged 5 commits into from
Nov 27, 2024
Merged

Conversation

juliusknorr
Copy link
Member

@juliusknorr juliusknorr commented Nov 14, 2024

This will make sure that lock owners can still unlock stale locks from clients that use the token type 2. We will show a confirmation dialog as revoking a lock could cause conflicts with file changes if the client comes back online assuming the lock would still be present.

Steps to test:

  • Connect the desktop client to a nextcloud server with this branch and files_lock app enabled
  • Sync an office document
  • Open the file on the desktop (e.g. with libreoffice)
  • The file shuld now be locked on the web UI
  • Kill the desktop client so the lock is stale
  • Try to unlock in the web

Replaces #172
Fix #325

  • Needs a proper UI component for the confirmation dialog

UI changes

  • Add hint if a client locked the file next to the user name (As the tooltip)
Screenshot 2024-11-15 at 10 39 31
  • Show confirmation modal when force unlocking another clients lock
Screenshot 2024-11-15 at 10 37 36

@juliusknorr juliusknorr added bug Something isn't working 3. to review labels Nov 15, 2024
@juliusknorr juliusknorr changed the title fix/unlock app lock Allow force unlock of automated client locks Nov 15, 2024
@juliusknorr juliusknorr marked this pull request as ready for review November 15, 2024 09:46
@juliusknorr
Copy link
Member Author

/backport to stable30

@juliusknorr
Copy link
Member Author

/backport to stable29

@juliusknorr
Copy link
Member Author

/backport to stable28

@juliusknorr
Copy link
Member Author

/backport to stable27

@juliusknorr
Copy link
Member Author

Will fix the conflict once I merged the remaining dependency updates on main

Signed-off-by: Julius Knorr <jus@bitgrid.net>
Signed-off-by: Julius Knorr <jus@bitgrid.net>
Signed-off-by: Julius Knorr <jus@bitgrid.net>
Signed-off-by: Julius Knorr <jus@bitgrid.net>
Copy link
Collaborator

@max-nextcloud max-nextcloud left a comment

Choose a reason for hiding this comment

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

Had a look at the code. Did not test it though.

Signed-off-by: Julius Knorr <jus@bitgrid.net>
@MaxXor
Copy link

MaxXor commented Dec 6, 2024

When can we see a release with this? 🙂

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
3. to review bug Something isn't working
Projects
Status: ☑️ Done
Development

Successfully merging this pull request may close these issues.

Please bring back the unlock feature
3 participants