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

[stable28] fix(settings): Disable renaming for tokens marked to be wiped #43195

Merged
merged 2 commits into from
Feb 1, 2024

Conversation

backportbot[bot]
Copy link

@backportbot backportbot bot commented Jan 29, 2024

Backport of #42331

Warning, This backport's changes differ from the original and might be incomplete ⚠️

Todo

  • Review and resolve any conflicts
  • Remove all the empty commits

Learn more about backports at https://docs.nextcloud.com/server/stable/go.php?to=developer-backports.

This otherwise a WipeException will be thrown when trying to rename

Signed-off-by: Ferdinand Thiessen <[email protected]>
@backportbot backportbot bot requested review from come-nc, emoral435 and susnux January 29, 2024 17:47
@backportbot backportbot bot added this to the Nextcloud 28.0.2 milestone Jan 29, 2024
@@ -105,7 +105,7 @@
return array_map(function (IToken $token) use ($sessionToken) {
$data = $token->jsonSerialize();
$data['canDelete'] = true;
$data['canRename'] = $token instanceof INamedToken;
$data['canRename'] = $token instanceof INamedToken && $data['type'] !== IToken::WIPE_TOKEN;

Check notice

Code scanning / Psalm

DeprecatedClass Note

Class OC\Authentication\Token\IToken is deprecated
Signed-off-by: Ferdinand Thiessen <[email protected]>
@susnux susnux force-pushed the backport/42331/stable28 branch from b1a0663 to a61c11f Compare January 29, 2024 21:06
@susnux susnux marked this pull request as ready for review January 29, 2024 21:14
@susnux susnux merged commit d501f2d into stable28 Feb 1, 2024
53 checks passed
@susnux susnux deleted the backport/42331/stable28 branch February 1, 2024 11:15
@skjnldsv skjnldsv mentioned this pull request Feb 14, 2024
8 tasks
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.

2 participants