Skip to content

Commit 67937a5

Browse files
authored
Merge pull request #48 from dsbilling/shift-76645
2 parents 3ce4b5f + 07c03a8 commit 67937a5

File tree

60 files changed

+1672
-1570
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

60 files changed

+1672
-1570
lines changed

.env.example

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ MAIL_PORT=1025
3232
MAIL_USERNAME=null
3333
MAIL_PASSWORD=null
3434
MAIL_ENCRYPTION=null
35-
MAIL_FROM_ADDRESS=null
35+
MAIL_FROM_ADDRESS=[email protected]
3636
MAIL_FROM_NAME="${APP_NAME}"
3737

3838
AWS_ACCESS_KEY_ID=

.github/workflows/laravel.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ jobs:
88
fail-fast: false
99
matrix:
1010
operating-system: [ubuntu-latest]
11-
php-versions: ['8.1']
11+
php-versions: [8.1]
1212
steps:
1313
- name: Checkout
1414
uses: actions/checkout@v3

app/Console/Kernel.php

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -7,15 +7,6 @@
77

88
class Kernel extends ConsoleKernel
99
{
10-
/**
11-
* The Artisan commands provided by your application.
12-
*
13-
* @var array
14-
*/
15-
protected $commands = [
16-
//
17-
];
18-
1910
/**
2011
* Define the application's command schedule.
2112
*

app/Exceptions/Handler.php

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,19 +7,28 @@
77

88
class Handler extends ExceptionHandler
99
{
10+
/**
11+
* A list of exception types with their corresponding custom log levels.
12+
*
13+
* @var array<class-string<\Throwable>, \Psr\Log\LogLevel::*>
14+
*/
15+
protected $levels = [
16+
//
17+
];
18+
1019
/**
1120
* A list of the exception types that are not reported.
1221
*
13-
* @var array
22+
* @var array<int, class-string<\Throwable>>
1423
*/
1524
protected $dontReport = [
1625
//
1726
];
1827

1928
/**
20-
* A list of the inputs that are never flashed for validation exceptions.
29+
* A list of the inputs that are never flashed to the session on validation exceptions.
2130
*
22-
* @var array
31+
* @var array<int, string>
2332
*/
2433
protected $dontFlash = [
2534
'current_password',

app/Http/Kernel.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ class Kernel extends HttpKernel
1616
protected $middleware = [
1717
// \App\Http\Middleware\TrustHosts::class,
1818
\App\Http\Middleware\TrustProxies::class,
19-
\Fruitcake\Cors\HandleCors::class,
19+
\Illuminate\Http\Middleware\HandleCors::class,
2020
\App\Http\Middleware\PreventRequestsDuringMaintenance::class,
2121
\Illuminate\Foundation\Http\Middleware\ValidatePostSize::class,
2222
\App\Http\Middleware\TrimStrings::class,
@@ -56,6 +56,7 @@ class Kernel extends HttpKernel
5656
protected $routeMiddleware = [
5757
'auth' => \App\Http\Middleware\Authenticate::class,
5858
'auth.basic' => \Illuminate\Auth\Middleware\AuthenticateWithBasicAuth::class,
59+
'auth.session' => \Illuminate\Session\Middleware\AuthenticateSession::class,
5960
'cache.headers' => \Illuminate\Http\Middleware\SetCacheHeaders::class,
6061
'can' => \Illuminate\Auth\Middleware\Authorize::class,
6162
'guest' => \App\Http\Middleware\RedirectIfAuthenticated::class,

app/Http/Middleware/TrimStrings.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ class TrimStrings extends Middleware
99
/**
1010
* The names of the attributes that should not be trimmed.
1111
*
12-
* @var array
12+
* @var array<int, string>
1313
*/
1414
protected $except = [
1515
'current_password',

app/Http/Middleware/TrustProxies.php

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,15 @@
22

33
namespace App\Http\Middleware;
44

5-
use Fideloper\Proxy\TrustProxies as Middleware;
5+
use Illuminate\Http\Middleware\TrustProxies as Middleware;
66
use Illuminate\Http\Request;
77

88
class TrustProxies extends Middleware
99
{
1010
/**
1111
* The trusted proxies for this application.
1212
*
13-
* @var array|string|null
13+
* @var array<int, string>|string|null
1414
*/
1515
protected $proxies;
1616

@@ -19,5 +19,10 @@ class TrustProxies extends Middleware
1919
*
2020
* @var int
2121
*/
22-
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;
22+
protected $headers =
23+
Request::HEADER_X_FORWARDED_FOR |
24+
Request::HEADER_X_FORWARDED_HOST |
25+
Request::HEADER_X_FORWARDED_PORT |
26+
Request::HEADER_X_FORWARDED_PROTO |
27+
Request::HEADER_X_FORWARDED_AWS_ELB;
2328
}
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
<?php
2+
3+
namespace App\Http\Middleware;
4+
5+
use Illuminate\Routing\Middleware\ValidateSignature as Middleware;
6+
7+
class ValidateSignature extends Middleware
8+
{
9+
/**
10+
* The names of the query string parameters that should be ignored.
11+
*
12+
* @var array<int, string>
13+
*/
14+
protected $except = [
15+
// 'fbclid',
16+
// 'utm_campaign',
17+
// 'utm_content',
18+
// 'utm_medium',
19+
// 'utm_source',
20+
// 'utm_term',
21+
];
22+
}

app/Models/Certification.php

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,10 @@ class Certification extends Model
2323
'file_path',
2424
];
2525

26-
protected $dates = ['issued_at', 'expiration_at'];
26+
protected $casts = [
27+
'issued_at' => 'datetime',
28+
'expiration_at' => 'datetime',
29+
];
2730

2831
/**
2932
* Get the company for the certification.

app/Models/Course.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,9 @@ class Course extends Model
2222
'file_path',
2323
];
2424

25-
protected $dates = ['issued_at'];
25+
protected $casts = [
26+
'issued_at' => 'datetime',
27+
];
2628

2729
/**
2830
* Get the company for the course.

0 commit comments

Comments
 (0)