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 URL signing for localized routes #78

Merged
merged 2 commits into from
Feb 26, 2024

Conversation

fyrts
Copy link
Contributor

@fyrts fyrts commented Feb 16, 2024

I've implemented signedLocalizedRoute and temporarySignedLocalizedRoute macros for Laravel's UrlGenerator, analogous to signedRoute and temporarySignedRoute.

use Illuminate\Support\Facades\URL;
 
return URL::signedLocalizedRoute('unsubscribe', ['user' => 1]);
use Illuminate\Support\Facades\URL;
 
return URL::temporarySignedLocalizedRoute(
    'unsubscribe', now()->addMinutes(30), ['user' => 1]
);

@fyrts fyrts marked this pull request as ready for review February 16, 2024 11:22
@chinleung chinleung merged commit 66a7e9b into chinleung:v4 Feb 26, 2024
3 of 4 checks passed
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

2 participants