-
-
Notifications
You must be signed in to change notification settings - Fork 994
Apply laravel 9 and laravel 10 upgrade guide #434
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
Changes from all commits
e910d8c
5e60463
8319de0
82e1ba1
ae1cb2d
04444ab
e3819c0
0ea1d82
874261b
bc2d0d3
8a24f9e
35a5501
98c0aa4
329a8f2
bd5540e
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -55,7 +55,7 @@ class Kernel extends HttpKernel | |
| * | ||
| * @var array | ||
| */ | ||
| protected $routeMiddleware = [ | ||
| protected $middlewareAliases = [ | ||
|
Owner
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. To clarify, did the variable name change within Laravel or is this a personal preference?
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. this is part of the upgrade guide https://laravel.com/docs/10.x/upgrade#middleware-aliases |
||
| 'auth' => \App\Http\Middleware\Authenticate::class, | ||
| 'auth.basic' => \Illuminate\Auth\Middleware\AuthenticateWithBasicAuth::class, | ||
| 'auth.session' => \Illuminate\Session\Middleware\AuthenticateSession::class, | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -13,16 +13,14 @@ class AuthServiceProvider extends ServiceProvider | |
| * @var array<class-string, class-string> | ||
| */ | ||
| protected $policies = [ | ||
| 'App\Models\Model' => 'App\Policies\ModelPolicy', | ||
| // 'App\Models\Model' => 'App\Policies\ModelPolicy', | ||
|
Owner
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Why comment it out?
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. It was triggering an error if not, to be honest I am not using it in my own project so I never checked how policies works |
||
| ]; | ||
|
|
||
| /** | ||
| * Register any authentication / authorization services. | ||
| */ | ||
| public function boot(): void | ||
| { | ||
| $this->registerPolicies(); | ||
|
|
||
| // | ||
| } | ||
| } | ||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
To confirm, this is because I changed the models to extend the packages models... correct?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes !