diff --git a/app/Http/Livewire/App/Register.php b/app/Http/Livewire/App/Register.php index 8e45286..8c66ffd 100644 --- a/app/Http/Livewire/App/Register.php +++ b/app/Http/Livewire/App/Register.php @@ -2,6 +2,7 @@ namespace App\Http\Livewire\App; +use Illuminate\Support\Facades\Auth; use Illuminate\Validation\Rules\Password; use Livewire\Component; @@ -49,5 +50,9 @@ public function register() $user->email = $this->credentials['email']; $user->save(); + + Auth::loginUsingId($user->id); + + return redirect()->route('front.index'); } } diff --git a/resources/views/livewire/front/index.blade.php b/resources/views/livewire/front/index.blade.php index 96ce94f..b8878d6 100644 --- a/resources/views/livewire/front/index.blade.php +++ b/resources/views/livewire/front/index.blade.php @@ -5,7 +5,9 @@
A place to share your knowledge.
-Implemented by Ricardo Sawir
+Implemented by Ricardo + Sawir