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

Add redirect path in config, if link is not valid #22

Closed
yelyas20 opened this issue Apr 28, 2020 · 5 comments
Closed

Add redirect path in config, if link is not valid #22

yelyas20 opened this issue Apr 28, 2020 · 5 comments

Comments

@yelyas20
Copy link

I need to set a link that contains message to user that says your link is not valid because...
The link should be set in config file
Thanks

@cesargb
Copy link
Owner

cesargb commented Apr 28, 2020

I've been thinking about this for a few days. Maybe something like this:

'invalid_response' => [
    /*
     | Method called when magiclink is invalid, method accepted: response, view, redirect, abort
   */
    'method' => 'response',
    'arguments => [
        'forbidden', 
        '403'
    ],
],

@dannydinges
Copy link

I submitted a pull request to define the controller where you could do whatever you'd want. I think it'd cover this situation for the user as well.

@yelyas20
Copy link
Author

yelyas20 commented May 9, 2020

I submitted a pull request to define the controller where you could do whatever you'd want. I think it'd cover this situation for the user as well.

Thank you

@cesargb
Copy link
Owner

cesargb commented May 16, 2020

@yelyas20 In the version 2.4.0, you have this features: https://github.com/cesargb/laravel-magiclink#custom-response-when-magiclink-is-invalid

I hope the documentation is clear enough.

@yelyas20
Copy link
Author

Thank you good man

@cesargb cesargb closed this as completed May 16, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants