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

[Feature]: Client: Preserve redirect URL on 401 response #38933

Closed
1 task done
albinAppsmith opened this issue Jan 31, 2025 · 0 comments · Fixed by #39296
Closed
1 task done

[Feature]: Client: Preserve redirect URL on 401 response #38933

albinAppsmith opened this issue Jan 31, 2025 · 0 comments · Fixed by #39296
Assignees
Labels
Enhancement New feature or request QA Needs QA attention

Comments

@albinAppsmith
Copy link
Collaborator

Is there an existing issue for this?

  • I have searched the existing issues

Summary

  1. Store the current URL before redirecting the user to login.
  2. Append this URL as a query param.
  3. After authentication, retrieve and redirect the user to the stored URL.

Why should this be worked on?

  1. Users expect to return to the page they were trying to access after logging in. Losing their intended destination creates frustration and disrupts their workflow.
  2. Without this fix, users may need to manually navigate back to their desired page after logging in, adding unnecessary steps.
  3. If a user’s session expires while they’re on a protected page, they should be able to log in and seamlessly continue where they left off.
@albinAppsmith albinAppsmith added Enhancement New feature or request Platform Administration Pod Issues related to platform administration & management labels Jan 31, 2025
@albinAppsmith albinAppsmith self-assigned this Jan 31, 2025
@github-actions github-actions bot removed the Platform Administration Pod Issues related to platform administration & management label Jan 31, 2025
@abhvsn abhvsn closed this as completed in e4ed590 Feb 18, 2025
@appsmith-bot appsmith-bot added the QA Needs QA attention label Feb 18, 2025
abhvsn added a commit that referenced this issue Feb 18, 2025
## Description
## Description

Added redirect URL on user logout

Fixes #38933

## Automation

/ok-to-test tags="@tag.Sanity"

### 🔍 Cypress test results
<!-- This is an auto-generated comment: Cypress test results  -->
> [!TIP]
> 🟢 🟢 🟢 All cypress tests have passed! 🎉 🎉 🎉
> Workflow run:
<https://github.com/appsmithorg/appsmith/actions/runs/13369328042>
> Commit: 5b4bbe9
> <a
href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=13369328042&attempt=1"
target="_blank">Cypress dashboard</a>.
> Tags: `@tag.Sanity`
> Spec:
> <hr>Mon, 17 Feb 2025 12:14:39 UTC
<!-- end of auto-generated comment: Cypress test results  -->

## Communication
Should the DevRel and Marketing teams inform users about this change?
- [ ] Yes
- [x] No

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

- **New Features**
- Users are now automatically redirected to the login page after logout
for a smoother navigation experience.
- **Refactor**
- Simplified the logout request process to consistently use the "POST"
method, enhancing reliability.
- Streamlined the interception logic for logout API calls, improving
overall consistency.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->

---------

Co-authored-by: Albin <[email protected]>
(cherry picked from commit e4ed590)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Enhancement New feature or request QA Needs QA attention
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants