Skip to content

Commit

Permalink
Merge pull request #67 from spatie/shift-115810
Browse files Browse the repository at this point in the history
Laravel 11.x Shift
  • Loading branch information
riasvdv authored Apr 11, 2024
2 parents 6fb0b4d + 2ec0006 commit b33aa1f
Show file tree
Hide file tree
Showing 55 changed files with 155 additions and 2,043 deletions.
18 changes: 16 additions & 2 deletions .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,20 @@ APP_NAME=Mailcoach
APP_ENV=local
APP_KEY=
APP_DEBUG=true
APP_TIMEZONE=UTC
APP_URL=http://localhost

APP_LOCALE=en
APP_FALLBACK_LOCALE=en
APP_FAKER_LOCALE=en_US

APP_MAINTENANCE_DRIVER=file
APP_MAINTENANCE_STORE=database

BCRYPT_ROUNDS=12

LOG_CHANNEL=stack
LOG_STACK=single
LOG_DEPRECATIONS_CHANNEL=null
LOG_LEVEL=debug

Expand All @@ -15,12 +26,15 @@ DB_DATABASE=mailcoach
DB_USERNAME=root
DB_PASSWORD=

BROADCAST_DRIVER=log
CACHE_DRIVER=file
BROADCAST_CONNECTION=log
CACHE_STORE=file
FILESYSTEM_DISK=local
QUEUE_CONNECTION=redis
SESSION_DRIVER=file
SESSION_LIFETIME=120
SESSION_ENCRYPT=false
SESSION_PATH=/
SESSION_DOMAIN=null

MEMCACHED_HOST=127.0.0.1

Expand Down
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -20,3 +20,5 @@ public/vendor
public/js/filament
public/css/filament
database/migrations

/.phpunit.cache
27 changes: 13 additions & 14 deletions app/Console/Commands/MakeUserCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,8 @@

namespace App\Console\Commands;

use App\User;
use App\Models\User;
use Illuminate\Console\Command;
use Illuminate\Contracts\Auth\Authenticatable;
use Illuminate\Support\Facades\Hash;
use Illuminate\Support\Facades\Validator;

Expand All @@ -29,20 +28,20 @@ protected function requestData(): array
{
return [
'name' => $this->option('username') ?? text(
label: 'Username',
required: true,
),
label: 'Username',
required: true,
),

'email' => $this->option('email') ?? text(
label: 'Email address',
required: true,
validate: fn (string $value) => match (true) {
! filter_var($value, FILTER_VALIDATE_EMAIL) => 'The email address must be valid.',
User::where('email', $value)->exists() => 'A user with this email address already exists.',
! is_null($error = $this->verifyDns($value)) => $error,
default => null,
},
),
label: 'Email address',
required: true,
validate: fn (string $value) => match (true) {
! filter_var($value, FILTER_VALIDATE_EMAIL) => 'The email address must be valid.',
User::where('email', $value)->exists() => 'A user with this email address already exists.',
! is_null($error = $this->verifyDns($value)) => $error,
default => null,
},
),

'password' => Hash::make($this->option('password') ?? password(
label: 'Password',
Expand Down
41 changes: 0 additions & 41 deletions app/Console/Kernel.php

This file was deleted.

2 changes: 1 addition & 1 deletion app/Http/Controllers/Auth/ForgotPasswordController.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@

class ForgotPasswordController
{
use SendsPasswordResetEmails;
use AuthorizesRequests;
use DispatchesJobs;
use SendsPasswordResetEmails;
use ValidatesRequests;

public function showLinkRequestForm()
Expand Down
1 change: 0 additions & 1 deletion app/Http/Controllers/Auth/LoginController.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
use Illuminate\Foundation\Auth\AuthenticatesUsers;
use Illuminate\Foundation\Bus\DispatchesJobs;
use Illuminate\Foundation\Validation\ValidatesRequests;
use Illuminate\Support\Facades\Auth;

class LoginController
{
Expand Down
2 changes: 1 addition & 1 deletion app/Http/Controllers/Auth/ResetPasswordController.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@

class ResetPasswordController
{
use ResetsPasswords;
use AuthorizesRequests;
use DispatchesJobs;
use ResetsPasswords;
use ValidatesRequests;

public function showResetForm(Request $request)
Expand Down
2 changes: 1 addition & 1 deletion app/Http/Controllers/Controller.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
use Illuminate\Foundation\Validation\ValidatesRequests;
use Illuminate\Routing\Controller as BaseController;

class Controller extends BaseController
abstract class Controller extends BaseController
{
use AuthorizesRequests, ValidatesRequests;
}
68 changes: 0 additions & 68 deletions app/Http/Kernel.php

This file was deleted.

17 changes: 0 additions & 17 deletions app/Http/Middleware/Authenticate.php

This file was deleted.

17 changes: 0 additions & 17 deletions app/Http/Middleware/EncryptCookies.php

This file was deleted.

17 changes: 0 additions & 17 deletions app/Http/Middleware/PreventRequestsDuringMaintenance.php

This file was deleted.

30 changes: 0 additions & 30 deletions app/Http/Middleware/RedirectIfAuthenticated.php

This file was deleted.

19 changes: 0 additions & 19 deletions app/Http/Middleware/TrimStrings.php

This file was deleted.

20 changes: 0 additions & 20 deletions app/Http/Middleware/TrustHosts.php

This file was deleted.

28 changes: 0 additions & 28 deletions app/Http/Middleware/TrustProxies.php

This file was deleted.

Loading

0 comments on commit b33aa1f

Please sign in to comment.