Skip to content

Conversation

@seongjinyoon
Copy link
Contributor

What changes were proposed in this PR?

This PR fixes a bug where workflow were cloned when users revoked their own access to a shared workflow while having it open in the workspace.

Bug:
When a user revoked their own access while editing a shared workflow, the frontend's auto-persist would continue to save changes. The backend's persistWorkflow method would receive these save requests from a user who no longer has access, and create a new workflow.

Changes Made:
Backend (WorkflowResource.scala):

  • Modified persistWorkflow() method to distinguish between:
    • Creating a new workflow (workflow ID is null)
    • Persisting an existing workflow without access (workflow ID is not null)

Frontend (ShareAccessComponent):

  • Added verifyRevokeAccess() method that shows a confirmation modal before revoking access.
  • Made revokeAccess() private and updated it to return a flag when user revokes their own access.

Frontend (MenuComponent):

  • Added redirect logic to navigate users to the workflows list page when they revoke their own access while in the workspace.

Frontend (share-access.component.html):

  • Updated delete button to call verifyRevokeAccess() instead of revokeAccess() to trigger confirmation popup.

Before:

Before.mov

After:

After.mov

Any related issues, documentation, discussions?

None.

How was this PR tested?

Manually tested.

Was this PR authored or co-authored using generative AI tooling?

No.

@chenlica
Copy link
Contributor

@Xiao-zhen-Liu Please review this PR.

@seongjinyoon seongjinyoon deleted the fix/remove-unused-endpoint branch January 13, 2026 01:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants