Skip to content

Fix project deploy key creation and deletion as admin

Stan Hu requested to merge sh-fix-issue-53783 into master

In EE, the DeployKeyController reloads the user's accesible key so that it can audit changes. However, this has a side effect of preventing admins from deleting keys in the interface. Note that this problem does not happen in CE because auditing is not performed there.

We can clean up the code by reusing the key that was created or destroyed and pushing the logic into the service.

Closes https://gitlab.com/gitlab-org/gitlab-ce/issues/53783

Edited by Stan Hu

Merge request reports