-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathv8.4.3...v9.0.0.diff
1683 lines (1598 loc) · 66.6 KB
/
v8.4.3...v9.0.0.diff
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
diff --git a/.editorconfig b/.editorconfig
index 6537ca46..1671c9b9 100644
--- a/.editorconfig
+++ b/.editorconfig
@@ -13,3 +13,6 @@ trim_trailing_whitespace = false
[*.{yml,yaml}]
indent_size = 2
+
+[docker-compose.yml]
+indent_size = 4
diff --git a/.env.example b/.env.example
index 7dc51e1f..8510237c 100644
--- a/.env.example
+++ b/.env.example
@@ -5,6 +5,7 @@ APP_DEBUG=true
APP_URL=http://localhost
LOG_CHANNEL=stack
+LOG_DEPRECATIONS_CHANNEL=null
LOG_LEVEL=debug
DB_CONNECTION=mysql
@@ -16,17 +17,20 @@ DB_PASSWORD=
BROADCAST_DRIVER=log
CACHE_DRIVER=file
+FILESYSTEM_DISK=local
QUEUE_CONNECTION=sync
SESSION_DRIVER=file
SESSION_LIFETIME=120
+MEMCACHED_HOST=127.0.0.1
+
REDIS_HOST=127.0.0.1
REDIS_PASSWORD=null
REDIS_PORT=6379
MAIL_MAILER=smtp
-MAIL_HOST=smtp.mailtrap.io
-MAIL_PORT=2525
+MAIL_HOST=mailhog
+MAIL_PORT=1025
MAIL_USERNAME=null
MAIL_PASSWORD=null
MAIL_ENCRYPTION=null
@@ -37,6 +41,7 @@ AWS_ACCESS_KEY_ID=
AWS_SECRET_ACCESS_KEY=
AWS_DEFAULT_REGION=us-east-1
AWS_BUCKET=
+AWS_USE_PATH_STYLE_ENDPOINT=false
PUSHER_APP_ID=
PUSHER_APP_KEY=
diff --git a/.gitattributes b/.gitattributes
index 967315dd..510d9961 100644
--- a/.gitattributes
+++ b/.gitattributes
@@ -1,5 +1,10 @@
* text=auto
-*.css linguist-vendored
-*.scss linguist-vendored
-*.js linguist-vendored
+
+*.blade.php diff=html
+*.css diff=css
+*.html diff=html
+*.md diff=markdown
+*.php diff=php
+
+/.github export-ignore
CHANGELOG.md export-ignore
diff --git a/.github/workflows/update-changelog.yml b/.github/workflows/update-changelog.yml
new file mode 100644
index 00000000..0200e2b9
--- /dev/null
+++ b/.github/workflows/update-changelog.yml
@@ -0,0 +1,29 @@
+name: "Update Changelog"
+
+on:
+ release:
+ types: [released]
+
+jobs:
+ update:
+ runs-on: ubuntu-latest
+
+ steps:
+ - name: Checkout code
+ uses: actions/checkout@v2
+ with:
+ ref: ${{ github.ref_name }}
+
+ - name: Update Changelog
+ uses: stefanzweifel/changelog-updater-action@v1
+ with:
+ latest-version: ${{ github.event.release.tag_name }}
+ release-notes: ${{ github.event.release.body }}
+ compare-url-target-revision: ${{ github.event.release.target_commitish }}
+
+ - name: Commit updated CHANGELOG
+ uses: stefanzweifel/git-auto-commit-action@v4
+ with:
+ branch: ${{ github.event.release.target_commitish }}
+ commit_message: Update CHANGELOG.md
+ file_pattern: CHANGELOG.md
diff --git a/.gitignore b/.gitignore
index 0f7df0fb..eb003b01 100644
--- a/.gitignore
+++ b/.gitignore
@@ -6,7 +6,10 @@
.env
.env.backup
.phpunit.result.cache
+docker-compose.override.yml
Homestead.json
Homestead.yaml
npm-debug.log
yarn-error.log
+/.idea
+/.vscode
diff --git a/.styleci.yml b/.styleci.yml
index 9231873a..679a631e 100644
--- a/.styleci.yml
+++ b/.styleci.yml
@@ -1,11 +1,11 @@
php:
preset: laravel
+ version: 8
disabled:
- no_unused_imports
finder:
not-name:
- index.php
- - server.php
js:
finder:
not-name:
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 80d51eb7..4d3b1735 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,97 +1,3 @@
# Release Notes
-## [Unreleased](https://github.com/laravel/laravel/compare/v8.4.3...8.x)
-
-
-## [v8.4.3 (2020-11-24)](https://github.com/laravel/laravel/compare/v8.4.2...v8.4.3)
-
-### Added
-- Add ably entry ([5182e9c](https://github.com/laravel/laravel/commit/5182e9c6de805e025fb4cfad63c210c3197002ab))
-
-### Fixed
-- Add missing null cache driver in `config/cache.php` ([#5472](https://github.com/laravel/laravel/pull/5472))
-
-
-## [v8.4.2 (2020-11-17)](https://github.com/laravel/laravel/compare/v8.4.1...v8.4.2)
-
-### Changed
-- Add sanctum cookie endpoint to default cors paths ([aa6d3660](https://github.com/laravel/laravel/commit/aa6d3660114c93e537a52e0ba3c03071a7f3e67f))
-- Modify the `cache.php` docblocks ([#5468](https://github.com/laravel/laravel/pull/5468))
-- Add stub handler ([4931af1](https://github.com/laravel/laravel/commit/4931af14006610bf8fd1f860cea1117c68133e94))
-
-### Fixed
-- Closed @auth correctly ([#5471](https://github.com/laravel/laravel/pull/5471))
-
-
-## [v8.4.1 (2020-11-10)](https://github.com/laravel/laravel/compare/v8.4.0...v8.4.1)
-
-### Changed
-- Add auth line ([b54ef29](https://github.com/laravel/laravel/commit/b54ef297b3c723c8438596c6e6afef93a7458b98))
-
-
-## [v8.4.0 (2020-10-30)](https://github.com/laravel/laravel/compare/v8.3.0...v8.4.0)
-
-### Changed
-- Bump several dependencies
-
-
-## [v8.3.0 (2020-10-29)](https://github.com/laravel/laravel/compare/v8.2.0...v8.3.0)
-
-### Added
-- PHP 8 Support ([4c25cb9](https://github.com/laravel/laravel/commit/4c25cb953a0bbd4812bf92af71a13920998def1e))
-
-### Changed
-- Update Faker ([#5461](https://github.com/laravel/laravel/pull/5461))
-- Update minimum Laravel version ([86d4ec0](https://github.com/laravel/laravel/commit/86d4ec095f1681df736d53206780d79f5857907c))
-- Revert to per user API rate limit ([#5456](https://github.com/laravel/laravel/pull/5456), [bec982b](https://github.com/laravel/laravel/commit/bec982b0a3962c8a3e1f665e987360bb8c056298))
-
-### Fixed
-- Delete removed webpack flag ([#5460](https://github.com/laravel/laravel/pull/5460))
-
-
-## [v8.2.0 (2020-10-20)](https://github.com/laravel/laravel/compare/v8.1.0...v8.2.0)
-
-### Added
-- Added 'LOG_LEVEL' env variable in `.env.example` ([#5445](https://github.com/laravel/laravel/pull/5445))
-- Add 'multiple_of' translation ([#5449](https://github.com/laravel/laravel/pull/5449))
-
-
-## [v8.1.0 (2020-10-06)](https://github.com/laravel/laravel/compare/v8.0.3...v8.1.0)
-
-### Added
-- Added `LOG_LEVEL` env variable ([#5442](https://github.com/laravel/laravel/pull/5442))
-
-### Changed
-- Type hint the middleware Request ([#5438](https://github.com/laravel/laravel/pull/5438))
-
-
-## [v8.0.3 (2020-09-22)](https://github.com/laravel/laravel/compare/v8.0.2...v8.0.3)
-
-### Changed
-- Add comment ([a6ca577](https://github.com/laravel/laravel/commit/a6ca5778391b150102637459ac3b2a42d78d495b))
-
-
-## [v8.0.2 (2020-09-22)](https://github.com/laravel/laravel/compare/v8.0.1...v8.0.2)
-
-### Changed
-- Fully qualified user model in seeder ([#5406](https://github.com/laravel/laravel/pull/5406))
-- Update model path in `AuthServiceProvider`'s policies ([#5412](https://github.com/laravel/laravel/pull/5412))
-- Add commented code ([69d0c50](https://github.com/laravel/laravel/commit/69d0c504e3ff01e0fd219e02ebac9b1c22151c2a))
-
-### Fixed
-- Swap route order ([292a5b2](https://github.com/laravel/laravel/commit/292a5b26a9293d82ab5a7d0bb81bba02ea71758e))
-- Fix route when uncomment $namespace ([#5424](https://github.com/laravel/laravel/pull/5424))
-
-### Removed
-- Removed `$namespace` property ([b33852e](https://github.com/laravel/laravel/commit/b33852ecace72791f4bc28b8dd84c108166512bf))
-
-
-## [v8.0.1 (2020-09-09)](https://github.com/laravel/laravel/compare/v8.0.0...v8.0.1)
-
-### Changed
-- Re-add property to route service provider ([9cbc381](https://github.com/laravel/laravel/commit/9cbc3819f7b1c268447996d347a1733aa68e16d7))
-
-
-## [v8.0.0 (2020-09-08)](https://github.com/laravel/laravel/compare/v7.30.1...v8.0.0)
-
-Laravel 8 comes with a lot of changes to the base skeleton. Please consult the diff to see what's changed.
+## [Unreleased](https://github.com/laravel/laravel/compare/v8.6.10...9.x)
diff --git a/README.md b/README.md
index 2f7ddcc6..f171ecac 100644
--- a/README.md
+++ b/README.md
@@ -25,7 +25,7 @@ Laravel is accessible, powerful, and provides tools required for large, robust a
Laravel has the most extensive and thorough [documentation](https://laravel.com/docs) and video tutorial library of all modern web application frameworks, making it a breeze to get started with the framework.
-If you don't feel like reading, [Laracasts](https://laracasts.com) can help. Laracasts contains over 1500 video tutorials on a range of topics including Laravel, modern PHP, unit testing, and JavaScript. Boost your skills by digging into our comprehensive video library.
+If you don't feel like reading, [Laracasts](https://laracasts.com) can help. Laracasts contains over 2000 video tutorials on a range of topics including Laravel, modern PHP, unit testing, and JavaScript. Boost your skills by digging into our comprehensive video library.
## Laravel Sponsors
@@ -42,7 +42,10 @@ We would like to extend our thanks to the following sponsors for funding Laravel
- **[Many](https://www.many.co.uk)**
- **[Webdock, Fast VPS Hosting](https://www.webdock.io/en)**
- **[DevSquad](https://devsquad.com)**
+- **[Curotec](https://www.curotec.com/services/technologies/laravel/)**
- **[OP.GG](https://op.gg)**
+- **[WebReinvent](https://webreinvent.com/?utm_source=laravel&utm_medium=github&utm_campaign=patreon-sponsors)**
+- **[Lendio](https://lendio.com)**
## Contributing
diff --git a/app/Console/Kernel.php b/app/Console/Kernel.php
index 69914e99..d8bc1d29 100644
--- a/app/Console/Kernel.php
+++ b/app/Console/Kernel.php
@@ -7,15 +7,6 @@ use Illuminate\Foundation\Console\Kernel as ConsoleKernel;
class Kernel extends ConsoleKernel
{
- /**
- * The Artisan commands provided by your application.
- *
- * @var array
- */
- protected $commands = [
- //
- ];
-
/**
* Define the application's command schedule.
*
diff --git a/app/Exceptions/Handler.php b/app/Exceptions/Handler.php
index f9644add..8e7fbd1b 100644
--- a/app/Exceptions/Handler.php
+++ b/app/Exceptions/Handler.php
@@ -10,7 +10,7 @@ class Handler extends ExceptionHandler
/**
* A list of the exception types that are not reported.
*
- * @var array
+ * @var array<int, class-string<Throwable>>
*/
protected $dontReport = [
//
@@ -19,9 +19,10 @@ class Handler extends ExceptionHandler
/**
* A list of the inputs that are never flashed for validation exceptions.
*
- * @var array
+ * @var array<int, string>
*/
protected $dontFlash = [
+ 'current_password',
'password',
'password_confirmation',
];
diff --git a/app/Http/Kernel.php b/app/Http/Kernel.php
index 30020a50..d3722c2d 100644
--- a/app/Http/Kernel.php
+++ b/app/Http/Kernel.php
@@ -11,7 +11,7 @@ class Kernel extends HttpKernel
*
* These middleware are run during every request to your application.
*
- * @var array
+ * @var array<int, class-string|string>
*/
protected $middleware = [
// \App\Http\Middleware\TrustHosts::class,
@@ -26,7 +26,7 @@ class Kernel extends HttpKernel
/**
* The application's route middleware groups.
*
- * @var array
+ * @var array<string, array<int, class-string|string>>
*/
protected $middlewareGroups = [
'web' => [
@@ -40,6 +40,7 @@ class Kernel extends HttpKernel
],
'api' => [
+ // \Laravel\Sanctum\Http\Middleware\EnsureFrontendRequestsAreStateful::class,
'throttle:api',
\Illuminate\Routing\Middleware\SubstituteBindings::class,
],
@@ -50,7 +51,7 @@ class Kernel extends HttpKernel
*
* These middleware may be assigned to groups or used individually.
*
- * @var array
+ * @var array<string, class-string|string>
*/
protected $routeMiddleware = [
'auth' => \App\Http\Middleware\Authenticate::class,
diff --git a/app/Http/Middleware/EncryptCookies.php b/app/Http/Middleware/EncryptCookies.php
index 033136ad..867695bd 100644
--- a/app/Http/Middleware/EncryptCookies.php
+++ b/app/Http/Middleware/EncryptCookies.php
@@ -9,7 +9,7 @@ class EncryptCookies extends Middleware
/**
* The names of the cookies that should not be encrypted.
*
- * @var array
+ * @var array<int, string>
*/
protected $except = [
//
diff --git a/app/Http/Middleware/PreventRequestsDuringMaintenance.php b/app/Http/Middleware/PreventRequestsDuringMaintenance.php
index e4956d0b..74cbd9a9 100644
--- a/app/Http/Middleware/PreventRequestsDuringMaintenance.php
+++ b/app/Http/Middleware/PreventRequestsDuringMaintenance.php
@@ -9,7 +9,7 @@ class PreventRequestsDuringMaintenance extends Middleware
/**
* The URIs that should be reachable while maintenance mode is enabled.
*
- * @var array
+ * @var array<int, string>
*/
protected $except = [
//
diff --git a/app/Http/Middleware/RedirectIfAuthenticated.php b/app/Http/Middleware/RedirectIfAuthenticated.php
index 362b48b0..a2813a06 100644
--- a/app/Http/Middleware/RedirectIfAuthenticated.php
+++ b/app/Http/Middleware/RedirectIfAuthenticated.php
@@ -13,9 +13,9 @@ class RedirectIfAuthenticated
* Handle an incoming request.
*
* @param \Illuminate\Http\Request $request
- * @param \Closure $next
+ * @param \Closure(\Illuminate\Http\Request): (\Illuminate\Http\Response|\Illuminate\Http\RedirectResponse) $next
* @param string|null ...$guards
- * @return mixed
+ * @return \Illuminate\Http\Response|\Illuminate\Http\RedirectResponse
*/
public function handle(Request $request, Closure $next, ...$guards)
{
diff --git a/app/Http/Middleware/TrimStrings.php b/app/Http/Middleware/TrimStrings.php
index 5a50e7b5..88cadcaa 100644
--- a/app/Http/Middleware/TrimStrings.php
+++ b/app/Http/Middleware/TrimStrings.php
@@ -9,9 +9,10 @@ class TrimStrings extends Middleware
/**
* The names of the attributes that should not be trimmed.
*
- * @var array
+ * @var array<int, string>
*/
protected $except = [
+ 'current_password',
'password',
'password_confirmation',
];
diff --git a/app/Http/Middleware/TrustHosts.php b/app/Http/Middleware/TrustHosts.php
index b0550cfc..7186414c 100644
--- a/app/Http/Middleware/TrustHosts.php
+++ b/app/Http/Middleware/TrustHosts.php
@@ -9,7 +9,7 @@ class TrustHosts extends Middleware
/**
* Get the host patterns that should be trusted.
*
- * @return array
+ * @return array<int, string|null>
*/
public function hosts()
{
diff --git a/app/Http/Middleware/TrustProxies.php b/app/Http/Middleware/TrustProxies.php
index 14befceb..3391630e 100644
--- a/app/Http/Middleware/TrustProxies.php
+++ b/app/Http/Middleware/TrustProxies.php
@@ -2,7 +2,7 @@
namespace App\Http\Middleware;
-use Fideloper\Proxy\TrustProxies as Middleware;
+use Illuminate\Http\Middleware\TrustProxies as Middleware;
use Illuminate\Http\Request;
class TrustProxies extends Middleware
@@ -10,7 +10,7 @@ class TrustProxies extends Middleware
/**
* The trusted proxies for this application.
*
- * @var array|string|null
+ * @var array<int, string>|string|null
*/
protected $proxies;
@@ -19,5 +19,10 @@ class TrustProxies extends Middleware
*
* @var int
*/
- protected $headers = Request::HEADER_X_FORWARDED_ALL;
+ protected $headers =
+ Request::HEADER_X_FORWARDED_FOR |
+ Request::HEADER_X_FORWARDED_HOST |
+ Request::HEADER_X_FORWARDED_PORT |
+ Request::HEADER_X_FORWARDED_PROTO |
+ Request::HEADER_X_FORWARDED_AWS_ELB;
}
diff --git a/app/Http/Middleware/VerifyCsrfToken.php b/app/Http/Middleware/VerifyCsrfToken.php
index 0c13b854..9e865217 100644
--- a/app/Http/Middleware/VerifyCsrfToken.php
+++ b/app/Http/Middleware/VerifyCsrfToken.php
@@ -9,7 +9,7 @@ class VerifyCsrfToken extends Middleware
/**
* The URIs that should be excluded from CSRF verification.
*
- * @var array
+ * @var array<int, string>
*/
protected $except = [
//
diff --git a/app/Models/User.php b/app/Models/User.php
index 804799ba..89963686 100644
--- a/app/Models/User.php
+++ b/app/Models/User.php
@@ -6,15 +6,16 @@ use Illuminate\Contracts\Auth\MustVerifyEmail;
use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Foundation\Auth\User as Authenticatable;
use Illuminate\Notifications\Notifiable;
+use Laravel\Sanctum\HasApiTokens;
class User extends Authenticatable
{
- use HasFactory, Notifiable;
+ use HasApiTokens, HasFactory, Notifiable;
/**
* The attributes that are mass assignable.
*
- * @var array
+ * @var array<int, string>
*/
protected $fillable = [
'name',
@@ -23,9 +24,9 @@ class User extends Authenticatable
];
/**
- * The attributes that should be hidden for arrays.
+ * The attributes that should be hidden for serialization.
*
- * @var array
+ * @var array<int, string>
*/
protected $hidden = [
'password',
@@ -33,9 +34,9 @@ class User extends Authenticatable
];
/**
- * The attributes that should be cast to native types.
+ * The attributes that should be cast.
*
- * @var array
+ * @var array<string, string>
*/
protected $casts = [
'email_verified_at' => 'datetime',
diff --git a/app/Providers/AuthServiceProvider.php b/app/Providers/AuthServiceProvider.php
index ce744916..22b77e6e 100644
--- a/app/Providers/AuthServiceProvider.php
+++ b/app/Providers/AuthServiceProvider.php
@@ -10,7 +10,7 @@ class AuthServiceProvider extends ServiceProvider
/**
* The policy mappings for the application.
*
- * @var array
+ * @var array<class-string, class-string>
*/
protected $policies = [
// 'App\Models\Model' => 'App\Policies\ModelPolicy',
diff --git a/app/Providers/EventServiceProvider.php b/app/Providers/EventServiceProvider.php
index a9f10a63..23499eb8 100644
--- a/app/Providers/EventServiceProvider.php
+++ b/app/Providers/EventServiceProvider.php
@@ -12,7 +12,7 @@ class EventServiceProvider extends ServiceProvider
/**
* The event listener mappings for the application.
*
- * @var array
+ * @var array<class-string, array<int, class-string>>
*/
protected $listen = [
Registered::class => [
diff --git a/app/Providers/RouteServiceProvider.php b/app/Providers/RouteServiceProvider.php
index 3bd3c81e..7c17d1f0 100644
--- a/app/Providers/RouteServiceProvider.php
+++ b/app/Providers/RouteServiceProvider.php
@@ -57,7 +57,7 @@ class RouteServiceProvider extends ServiceProvider
protected function configureRateLimiting()
{
RateLimiter::for('api', function (Request $request) {
- return Limit::perMinute(60)->by(optional($request->user())->id ?: $request->ip());
+ return Limit::perMinute(60)->by($request->user()?->id ?: $request->ip());
});
}
}
diff --git a/artisan b/artisan
index 5c23e2e2..67a3329b 100755
--- a/artisan
+++ b/artisan
@@ -11,7 +11,7 @@ define('LARAVEL_START', microtime(true));
| Composer provides a convenient, automatically generated class loader
| for our application. We just need to utilize it! We'll require it
| into the script here so that we do not have to worry about the
-| loading of any our classes "manually". Feels great to relax.
+| loading of any of our classes manually. It's great to relax.
|
*/
diff --git a/composer.json b/composer.json
index 9d06962b..69137367 100644
--- a/composer.json
+++ b/composer.json
@@ -2,35 +2,23 @@
"name": "laravel/laravel",
"type": "project",
"description": "The Laravel Framework.",
- "keywords": [
- "framework",
- "laravel"
- ],
+ "keywords": ["framework", "laravel"],
"license": "MIT",
"require": {
- "php": "^7.3|^8.0",
- "fideloper/proxy": "^4.4",
- "fruitcake/laravel-cors": "^2.0",
- "guzzlehttp/guzzle": "^7.0.1",
- "laravel/framework": "^8.12",
- "laravel/tinker": "^2.5"
+ "php": "^8.0",
+ "fruitcake/laravel-cors": "^2.0.5",
+ "guzzlehttp/guzzle": "^7.2",
+ "laravel/framework": "^9.0",
+ "laravel/sanctum": "^2.14",
+ "laravel/tinker": "^2.7"
},
"require-dev": {
- "facade/ignition": "^2.5",
"fakerphp/faker": "^1.9.1",
- "mockery/mockery": "^1.4.2",
- "nunomaduro/collision": "^5.0",
- "phpunit/phpunit": "^9.3.3"
- },
- "config": {
- "optimize-autoloader": true,
- "preferred-install": "dist",
- "sort-packages": true
- },
- "extra": {
- "laravel": {
- "dont-discover": []
- }
+ "laravel/sail": "^1.0.1",
+ "mockery/mockery": "^1.4.4",
+ "nunomaduro/collision": "^6.1",
+ "phpunit/phpunit": "^9.5.10",
+ "spatie/laravel-ignition": "^1.0"
},
"autoload": {
"psr-4": {
@@ -44,18 +32,31 @@
"Tests\\": "tests/"
}
},
- "minimum-stability": "dev",
- "prefer-stable": true,
"scripts": {
"post-autoload-dump": [
"Illuminate\\Foundation\\ComposerScripts::postAutoloadDump",
"@php artisan package:discover --ansi"
],
+ "post-update-cmd": [
+ "@php artisan vendor:publish --tag=laravel-assets --ansi --force"
+ ],
"post-root-package-install": [
"@php -r \"file_exists('.env') || copy('.env.example', '.env');\""
],
"post-create-project-cmd": [
"@php artisan key:generate --ansi"
]
- }
+ },
+ "extra": {
+ "laravel": {
+ "dont-discover": []
+ }
+ },
+ "config": {
+ "optimize-autoloader": true,
+ "preferred-install": "dist",
+ "sort-packages": true
+ },
+ "minimum-stability": "dev",
+ "prefer-stable": true
}
diff --git a/config/app.php b/config/app.php
index 8409e00e..1941d7c7 100644
--- a/config/app.php
+++ b/config/app.php
@@ -1,5 +1,7 @@
<?php
+use Illuminate\Support\Facades\Facade;
+
return [
/*
@@ -188,45 +190,8 @@ return [
|
*/
- 'aliases' => [
-
- 'App' => Illuminate\Support\Facades\App::class,
- 'Arr' => Illuminate\Support\Arr::class,
- 'Artisan' => Illuminate\Support\Facades\Artisan::class,
- 'Auth' => Illuminate\Support\Facades\Auth::class,
- 'Blade' => Illuminate\Support\Facades\Blade::class,
- 'Broadcast' => Illuminate\Support\Facades\Broadcast::class,
- 'Bus' => Illuminate\Support\Facades\Bus::class,
- 'Cache' => Illuminate\Support\Facades\Cache::class,
- 'Config' => Illuminate\Support\Facades\Config::class,
- 'Cookie' => Illuminate\Support\Facades\Cookie::class,
- 'Crypt' => Illuminate\Support\Facades\Crypt::class,
- 'DB' => Illuminate\Support\Facades\DB::class,
- 'Eloquent' => Illuminate\Database\Eloquent\Model::class,
- 'Event' => Illuminate\Support\Facades\Event::class,
- 'File' => Illuminate\Support\Facades\File::class,
- 'Gate' => Illuminate\Support\Facades\Gate::class,
- 'Hash' => Illuminate\Support\Facades\Hash::class,
- 'Http' => Illuminate\Support\Facades\Http::class,
- 'Lang' => Illuminate\Support\Facades\Lang::class,
- 'Log' => Illuminate\Support\Facades\Log::class,
- 'Mail' => Illuminate\Support\Facades\Mail::class,
- 'Notification' => Illuminate\Support\Facades\Notification::class,
- 'Password' => Illuminate\Support\Facades\Password::class,
- 'Queue' => Illuminate\Support\Facades\Queue::class,
- 'Redirect' => Illuminate\Support\Facades\Redirect::class,
- 'Redis' => Illuminate\Support\Facades\Redis::class,
- 'Request' => Illuminate\Support\Facades\Request::class,
- 'Response' => Illuminate\Support\Facades\Response::class,
- 'Route' => Illuminate\Support\Facades\Route::class,
- 'Schema' => Illuminate\Support\Facades\Schema::class,
- 'Session' => Illuminate\Support\Facades\Session::class,
- 'Storage' => Illuminate\Support\Facades\Storage::class,
- 'Str' => Illuminate\Support\Str::class,
- 'URL' => Illuminate\Support\Facades\URL::class,
- 'Validator' => Illuminate\Support\Facades\Validator::class,
- 'View' => Illuminate\Support\Facades\View::class,
-
- ],
+ 'aliases' => Facade::defaultAliases()->merge([
+ // ...
+ ])->toArray(),
];
diff --git a/config/auth.php b/config/auth.php
index ba1a4d8c..d8c6cee7 100644
--- a/config/auth.php
+++ b/config/auth.php
@@ -31,7 +31,7 @@ return [
| users are actually retrieved out of your database or other storage
| mechanisms used by this application to persist your user's data.
|
- | Supported: "session", "token"
+ | Supported: "session"
|
*/
@@ -40,12 +40,6 @@ return [
'driver' => 'session',
'provider' => 'users',
],
-
- 'api' => [
- 'driver' => 'token',
- 'provider' => 'users',
- 'hash' => false,
- ],
],
/*
@@ -86,7 +80,7 @@ return [
| than one user table or model in the application and you want to have
| separate password reset settings based on the specific user types.
|
- | The expire time is the number of minutes that the reset token should be
+ | The expire time is the number of minutes that each reset token will be
| considered valid. This security feature keeps tokens short-lived so
| they have less time to be guessed. You may change this as needed.
|
diff --git a/config/broadcasting.php b/config/broadcasting.php
index ef208598..67fcbbd6 100644
--- a/config/broadcasting.php
+++ b/config/broadcasting.php
@@ -11,7 +11,7 @@ return [
| framework when an event needs to be broadcast. You may set this to
| any of the connections defined in the "connections" array below.
|
- | Supported: "pusher", "redis", "log", "null"
+ | Supported: "pusher", "ably", "redis", "log", "null"
|
*/
@@ -39,6 +39,9 @@ return [
'cluster' => env('PUSHER_APP_CLUSTER'),
'useTLS' => true,
],
+ 'client_options' => [
+ // Guzzle client options: https://docs.guzzlephp.org/en/stable/request-options.html
+ ],
],
'ably' => [
diff --git a/config/cache.php b/config/cache.php
index 9473acc9..8736c7a7 100644
--- a/config/cache.php
+++ b/config/cache.php
@@ -27,7 +27,7 @@ return [
| same cache driver to group types of items stored in your caches.
|
| Supported drivers: "apc", "array", "database", "file",
- | "memcached", "redis", "dynamodb", "null"
+ | "memcached", "redis", "dynamodb", "octane", "null"
|
*/
@@ -46,6 +46,7 @@ return [
'driver' => 'database',
'table' => 'cache',
'connection' => null,
+ 'lock_connection' => null,
],
'file' => [
@@ -75,6 +76,7 @@ return [
'redis' => [
'driver' => 'redis',
'connection' => 'cache',
+ 'lock_connection' => 'default',
],
'dynamodb' => [
@@ -86,6 +88,10 @@ return [
'endpoint' => env('DYNAMODB_ENDPOINT'),
],
+ 'octane' => [
+ 'driver' => 'octane',
+ ],
+
],
/*
diff --git a/config/database.php b/config/database.php
index b42d9b30..0faebaee 100644
--- a/config/database.php
+++ b/config/database.php
@@ -74,7 +74,7 @@ return [
'charset' => 'utf8',
'prefix' => '',
'prefix_indexes' => true,
- 'schema' => 'public',
+ 'search_path' => 'public',
'sslmode' => 'prefer',
],
@@ -129,7 +129,7 @@ return [
'default' => [
'url' => env('REDIS_URL'),
'host' => env('REDIS_HOST', '127.0.0.1'),
- 'password' => env('REDIS_PASSWORD', null),
+ 'password' => env('REDIS_PASSWORD'),
'port' => env('REDIS_PORT', '6379'),
'database' => env('REDIS_DB', '0'),
],
@@ -137,7 +137,7 @@ return [
'cache' => [
'url' => env('REDIS_URL'),
'host' => env('REDIS_HOST', '127.0.0.1'),
- 'password' => env('REDIS_PASSWORD', null),
+ 'password' => env('REDIS_PASSWORD'),
'port' => env('REDIS_PORT', '6379'),
'database' => env('REDIS_CACHE_DB', '1'),
],
diff --git a/config/filesystems.php b/config/filesystems.php
index 94c81126..cf5abce7 100644
--- a/config/filesystems.php
+++ b/config/filesystems.php
@@ -13,20 +13,7 @@ return [
|
*/
- 'default' => env('FILESYSTEM_DRIVER', 'local'),
-
- /*
- |--------------------------------------------------------------------------
- | Default Cloud Filesystem Disk
- |--------------------------------------------------------------------------
- |
- | Many applications store files both locally and in the cloud. For this
- | reason, you may specify a default "cloud" driver here. This driver
- | will be bound as the Cloud disk implementation in the container.
- |
- */
-
- 'cloud' => env('FILESYSTEM_CLOUD', 's3'),
+ 'default' => env('FILESYSTEM_DISK', 'local'),
/*
|--------------------------------------------------------------------------
@@ -63,6 +50,7 @@ return [
'bucket' => env('AWS_BUCKET'),
'url' => env('AWS_URL'),
'endpoint' => env('AWS_ENDPOINT'),
+ 'use_path_style_endpoint' => env('AWS_USE_PATH_STYLE_ENDPOINT', false),
],
],
diff --git a/config/hashing.php b/config/hashing.php
index 84257708..bcd3be4c 100644
--- a/config/hashing.php
+++ b/config/hashing.php
@@ -44,9 +44,9 @@ return [
*/
'argon' => [
- 'memory' => 1024,
- 'threads' => 2,
- 'time' => 2,
+ 'memory' => 65536,
+ 'threads' => 1,
+ 'time' => 4,
],
];
diff --git a/config/logging.php b/config/logging.php
index 6aa77fe2..fefe0885 100644
--- a/config/logging.php
+++ b/config/logging.php
@@ -19,6 +19,19 @@ return [
'default' => env('LOG_CHANNEL', 'stack'),
+ /*
+ |--------------------------------------------------------------------------
+ | Deprecations Log Channel
+ |--------------------------------------------------------------------------
+ |
+ | This option controls the log channel that should be used to log warnings
+ | regarding deprecated PHP and library features. This allows you to get
+ | your application ready for upcoming major versions of dependencies.
+ |
+ */
+
+ 'deprecations' => env('LOG_DEPRECATIONS_CHANNEL', 'null'),
+
/*
|--------------------------------------------------------------------------
| Log Channels
@@ -65,15 +78,17 @@ return [
'papertrail' => [
'driver' => 'monolog',
'level' => env('LOG_LEVEL', 'debug'),
- 'handler' => SyslogUdpHandler::class,
+ 'handler' => env('LOG_PAPERTRAIL_HANDLER', SyslogUdpHandler::class),
'handler_with' => [
'host' => env('PAPERTRAIL_URL'),
'port' => env('PAPERTRAIL_PORT'),
+ 'connectionString' => 'tls://'.env('PAPERTRAIL_URL').':'.env('PAPERTRAIL_PORT'),
],
],
'stderr' => [
'driver' => 'monolog',
+ 'level' => env('LOG_LEVEL', 'debug'),
'handler' => StreamHandler::class,
'formatter' => env('LOG_STDERR_FORMATTER'),
'with' => [
diff --git a/config/mail.php b/config/mail.php
index 54299aab..87b6fe3c 100644
--- a/config/mail.php
+++ b/config/mail.php
@@ -29,7 +29,7 @@ return [
| mailers below. You are free to add additional mailers as required.
|
| Supported: "smtp", "sendmail", "mailgun", "ses",
- | "postmark", "log", "array"
+ | "postmark", "log", "array", "failover"
|
*/
@@ -42,7 +42,6 @@ return [
'username' => env('MAIL_USERNAME'),
'password' => env('MAIL_PASSWORD'),
'timeout' => null,
- 'auth_mode' => null,
],
'ses' => [
@@ -59,7 +58,7 @@ return [
'sendmail' => [
'transport' => 'sendmail',
- 'path' => '/usr/sbin/sendmail -bs',
+ 'path' => env('MAIL_SENDMAIL_PATH', '/usr/sbin/sendmail -t -i'),
],
'log' => [
@@ -70,6 +69,14 @@ return [
'array' => [
'transport' => 'array',
],
+
+ 'failover' => [
+ 'transport' => 'failover',
+ 'mailers' => [
+ 'smtp',
+ 'log',
+ ],
+ ],
],
/*
diff --git a/config/queue.php b/config/queue.php
index 12222966..25ea5a81 100644
--- a/config/queue.php
+++ b/config/queue.php
@@ -39,6 +39,7 @@ return [
'table' => 'jobs',
'queue' => 'default',
'retry_after' => 90,
+ 'after_commit' => false,
],
'beanstalkd' => [
@@ -47,6 +48,7 @@ return [
'queue' => 'default',
'retry_after' => 90,
'block_for' => 0,
+ 'after_commit' => false,