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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

馃獎 Bug Fix: Added a check if redirect_on_register is allowed #22

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

ibnsultan
Copy link

Bug Fix: Added a check if redirect_on_register is allowed

Issue

The method register() currently faces a limitation where it cannot return its output due to enforced redirection, impacting API-first applications/requests or those aiming to handle the method's return manually

Details of Changes

I introduced a check to see if the REDIRECT_ON_REGISTER configuration option is enabled. This change ensures that the redirection after user registration only occurs if explicitly allowed by the configuration.

I modified the code block responsible for redirecting users after registration to include a conditional check for the REDIRECT_ON_REGISTER configuration option. If this option is enabled, the redirection will proceed; otherwise, there will be a return value

Benefits

  • Enhanced Configurability: By introducing this check, we provide administrators with greater control over the behaviour of the application after user registration.

Compatibility

This change does not impact any existing features or functionalities of the application. It operates within the existing framework, ensuring seamless integration with the authentication module.

Documentation Update

An update to the LeafMVC documentation is necessary to reflect the addition of the REDIRECT_ON_REGISTER configuration option within the authentication module. This ensures that users and developers are aware of this configurable behaviour and can utilize it effectively.

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.

None yet

1 participant