Skip to content

Commit

Permalink
up
Browse files Browse the repository at this point in the history
  • Loading branch information
marco76tv committed Sep 5, 2024
1 parent 1dca254 commit dcc84e7
Show file tree
Hide file tree
Showing 17 changed files with 322 additions and 604 deletions.
4 changes: 2 additions & 2 deletions Http/Controllers/Auth/EmailVerificationController.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,11 @@ class EmailVerificationController extends Controller
{
public function __invoke(string $id, string $hash): RedirectResponse
{
if (! hash_equals((string) $id, (string) Auth::user()->getKey())) {
if (! hash_equals($id, (string) Auth::user()->getKey())) {
throw new AuthorizationException();
}

if (! hash_equals((string) $hash, sha1(Auth::user()->getEmailForVerification()))) {
if (! hash_equals($hash, sha1((string) Auth::user()->getEmailForVerification()))) {
throw new AuthorizationException();
}

Expand Down
44 changes: 44 additions & 0 deletions Resources/dist/assets/app-AdGbOmQW.js

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions Resources/dist/assets/app-C2W6N_zY.css

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions Resources/dist/manifest.json
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
{
"Resources/css/app.css": {
"file": "assets/app-DOLvDdcZ.css",
"file": "assets/app-C2W6N_zY.css",
"src": "Resources/css/app.css",
"isEntry": true
},
"Resources/js/app.js": {
"file": "assets/app-Cz_D6cQF.js",
"file": "assets/app-AdGbOmQW.js",
"name": "app",
"src": "Resources/js/app.js",
"isEntry": true
Expand Down
2 changes: 1 addition & 1 deletion Resources/views/pages/auth/login.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ public function authenticate()
if (!Auth::attempt(['email' => $this->email, 'password' => $this->password], $this->remember)) {
$this->addError('email', trans('auth.failed'));
return;
return null;
}
event(new Login(auth()->guard('web'), User::where('email', $this->email)->first(), $this->remember));
Expand Down
2 changes: 1 addition & 1 deletion Resources/views/pages/auth/logout.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
{
public function logout()
public function logout(): never
{
dd('a');
app(LogoutUserAction::class)->execute(auth()->user());
Expand Down
5 changes: 3 additions & 2 deletions Resources/views/pages/auth/password/[token].blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
public $password;
public $passwordConfirmation;
public function mount($token)
public function mount($token): void
{
$this->email = request()->query('email', '');
$this->token = $token;
Expand All @@ -41,7 +41,7 @@ public function resetPassword()
'email' => $this->email,
'password' => $this->password,
],
function ($user, $password) {
function ($user, $password): void {
$user->password = Hash::make($password);
$user->setRememberToken(Str::random(60));
Expand All @@ -61,6 +61,7 @@ function ($user, $password) {
}
$this->addError('email', trans($response));
return null;
}
};
Expand Down
4 changes: 2 additions & 2 deletions Resources/views/pages/auth/password/reset.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,11 @@
new class extends Component
{
#[Validate('required|email')]
public $email = null;
public $email;
public $emailSentMessage = false;
public function sendResetPasswordLink()
public function sendResetPasswordLink(): void
{
$this->validate();
Expand Down
2 changes: 1 addition & 1 deletion Resources/views/pages/auth/verify.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
new class extends Component
{
public function resend()
public function resend(): void
{
$user = auth()->user();
if ($user->hasVerifiedEmail()) {
Expand Down
8 changes: 4 additions & 4 deletions Resources/views/pages/genesis/power-ups.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@
new class extends Component
{
public $powerups = [];
public $powerupsJSON = null;
public $powerupsJSON;
public function mount()
public function mount(): void
{
$json_path=public_path('/genesis/power-ups.json');
if(!File::exists($json_path)){
Expand All @@ -27,7 +27,7 @@ public function mount()
}
}
protected function fetchPowerup($repo, $installed)
protected function fetchPowerup(string $repo, $installed): \stdClass|array
{
$response = Http::get('https://raw.githubusercontent.com/' . $repo . '/main/powerup.json');
if ($response->successful()) {
Expand All @@ -39,7 +39,7 @@ protected function fetchPowerup($repo, $installed)
return [];
}
public function install($repo, $index)
public function install(string $repo, $index)
{
foreach ($this->powerupsJSON as $powerUpIndex => $powerup) {
if (key($powerup) == $repo) {
Expand Down
2 changes: 1 addition & 1 deletion Resources/views/pages/index.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
new class extends Component
{
public function test()
public function test(): void
{
//dddx(auth()->user()->consecutiveDaysLogin());
//Notifications::alignment(Alignment::Center);
Expand Down
2 changes: 1 addition & 1 deletion Resources/views/pages/learn/index.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
new class extends Component {
public $readme = '';
public function mount()
public function mount(): void
{
$this->readme = Http::get('https://raw.githubusercontent.com/thedevdojo/genesis/main/README.md')->body();
}
Expand Down
12 changes: 6 additions & 6 deletions Resources/views/pages/profile/edit.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,16 +26,16 @@
public $new_password_confirmation = '';
public $delete_confirm_password = '';
public function mount()
public function mount(): void
{
$this->user = auth()->user();
$this->name = $this->user->name;
$this->email = $this->user->email;
}
public function updateProfile()
public function updateProfile(): void
{
$validated = $this->validate([
$this->validate([
'name' => 'required|string|min:3',
'email' => 'required|min:3|email|max:255|unique:users,email,' . $this->user->id . ',id',
]);
Expand All @@ -51,9 +51,9 @@ public function updateProfile()
$this->dispatch('toast', message: 'Successfully updated profile.', data: ['position' => 'top-right', 'type' => 'success']);
}
public function updatePassword()
public function updatePassword(): void
{
$validated = $this->validate();
$this->validate();
if (!Hash::check($this->current_password, $this->user->password)) {
$this->dispatch('toast', message: 'Current Password Incorrect', data: ['position' => 'top-right', 'type' => 'danger']);
Expand All @@ -71,7 +71,7 @@ public function destroy()
if (!Hash::check($this->delete_confirm_password, $this->user->password)) {
$this->dispatch('toast', message: 'The Password you entered is incorrect', data: ['position' => 'top-right', 'type' => 'danger']);
$this->reset(['delete_confirm_password']);
return;
return null;
}
$user = auth()->user();
Expand Down
157 changes: 35 additions & 122 deletions bootstrap/cache/packages.php
Original file line number Diff line number Diff line change
@@ -1,122 +1,35 @@
<?php return array (
'anourvalar/eloquent-serialize' =>
array (
'aliases' =>
array (
'EloquentSerialize' => 'AnourValar\\EloquentSerialize\\Facades\\EloquentSerializeFacade',
),
),
'blade-ui-kit/blade-heroicons' =>
array (
'providers' =>
array (
0 => 'BladeUI\\Heroicons\\BladeHeroiconsServiceProvider',
),
),
'blade-ui-kit/blade-icons' =>
array (
'providers' =>
array (
0 => 'BladeUI\\Icons\\BladeIconsServiceProvider',
),
),
'filament/actions' =>
array (
'providers' =>
array (
0 => 'Filament\\Actions\\ActionsServiceProvider',
),
),
'filament/filament' =>
array (
'providers' =>
array (
0 => 'Filament\\FilamentServiceProvider',
),
),
'filament/forms' =>
array (
'providers' =>
array (
0 => 'Filament\\Forms\\FormsServiceProvider',
),
),
'filament/infolists' =>
array (
'providers' =>
array (
0 => 'Filament\\Infolists\\InfolistsServiceProvider',
),
),
'filament/notifications' =>
array (
'providers' =>
array (
0 => 'Filament\\Notifications\\NotificationsServiceProvider',
),
),
'filament/support' =>
array (
'providers' =>
array (
0 => 'Filament\\Support\\SupportServiceProvider',
),
),
'filament/tables' =>
array (
'providers' =>
array (
0 => 'Filament\\Tables\\TablesServiceProvider',
),
),
'filament/widgets' =>
array (
'providers' =>
array (
0 => 'Filament\\Widgets\\WidgetsServiceProvider',
),
),
'kirschbaum-development/eloquent-power-joins' =>
array (
'providers' =>
array (
0 => 'Kirschbaum\\PowerJoins\\PowerJoinsServiceProvider',
),
),
'livewire/livewire' =>
array (
'providers' =>
array (
0 => 'Livewire\\LivewireServiceProvider',
),
'aliases' =>
array (
'Livewire' => 'Livewire\\Livewire',
),
),
'nesbot/carbon' =>
array (
'providers' =>
array (
0 => 'Carbon\\Laravel\\ServiceProvider',
),
),
'nunomaduro/termwind' =>
array (
'providers' =>
array (
0 => 'Termwind\\Laravel\\TermwindServiceProvider',
),
),
'ryangjchandler/blade-capture-directive' =>
array (
'providers' =>
array (
0 => 'RyanChandler\\BladeCaptureDirective\\BladeCaptureDirectiveServiceProvider',
),
'aliases' =>
array (
'BladeCaptureDirective' => 'RyanChandler\\BladeCaptureDirective\\Facades\\BladeCaptureDirective',
),
),
);
<?php return ['anourvalar/eloquent-serialize' =>
['aliases' =>
['EloquentSerialize' => \AnourValar\EloquentSerialize\Facades\EloquentSerializeFacade::class]], 'blade-ui-kit/blade-heroicons' =>
['providers' =>
[0 => \BladeUI\Heroicons\BladeHeroiconsServiceProvider::class]], 'blade-ui-kit/blade-icons' =>
['providers' =>
[0 => \BladeUI\Icons\BladeIconsServiceProvider::class]], 'filament/actions' =>
['providers' =>
[0 => \Filament\Actions\ActionsServiceProvider::class]], 'filament/filament' =>
['providers' =>
[0 => \Filament\FilamentServiceProvider::class]], 'filament/forms' =>
['providers' =>
[0 => \Filament\Forms\FormsServiceProvider::class]], 'filament/infolists' =>
['providers' =>
[0 => \Filament\Infolists\InfolistsServiceProvider::class]], 'filament/notifications' =>
['providers' =>
[0 => \Filament\Notifications\NotificationsServiceProvider::class]], 'filament/support' =>
['providers' =>
[0 => \Filament\Support\SupportServiceProvider::class]], 'filament/tables' =>
['providers' =>
[0 => \Filament\Tables\TablesServiceProvider::class]], 'filament/widgets' =>
['providers' =>
[0 => \Filament\Widgets\WidgetsServiceProvider::class]], 'kirschbaum-development/eloquent-power-joins' =>
['providers' =>
[0 => \Kirschbaum\PowerJoins\PowerJoinsServiceProvider::class]], 'livewire/livewire' =>
['providers' =>
[0 => \Livewire\LivewireServiceProvider::class], 'aliases' =>
['Livewire' => \Livewire\Livewire::class]], 'nesbot/carbon' =>
['providers' =>
[0 => \Carbon\Laravel\ServiceProvider::class]], 'nunomaduro/termwind' =>
['providers' =>
[0 => \Termwind\Laravel\TermwindServiceProvider::class]], 'ryangjchandler/blade-capture-directive' =>
['providers' =>
[0 => \RyanChandler\BladeCaptureDirective\BladeCaptureDirectiveServiceProvider::class], 'aliases' =>
['BladeCaptureDirective' => 'RyanChandler\\BladeCaptureDirective\\Facades\\BladeCaptureDirective']]];
Loading

0 comments on commit dcc84e7

Please sign in to comment.