mirror of
https://github.com/Bubka/2FAuth.git
synced 2025-06-04 20:17:27 +02:00
Fix case typo in filename
This commit is contained in:
parent
fee7a684b2
commit
9c199dc7d5
@ -5,7 +5,7 @@ namespace App\Events;
|
|||||||
use Illuminate\Foundation\Events\Dispatchable;
|
use Illuminate\Foundation\Events\Dispatchable;
|
||||||
use Illuminate\Support\Facades\Log;
|
use Illuminate\Support\Facades\Log;
|
||||||
|
|
||||||
class storeIconsInDatabaseSettingChanged
|
class StoreIconsInDatabaseSettingChanged
|
||||||
{
|
{
|
||||||
use Dispatchable;
|
use Dispatchable;
|
||||||
|
|
||||||
@ -22,6 +22,6 @@ class storeIconsInDatabaseSettingChanged
|
|||||||
public function __construct(bool $newValue)
|
public function __construct(bool $newValue)
|
||||||
{
|
{
|
||||||
$this->newValue = $newValue;
|
$this->newValue = $newValue;
|
||||||
Log::info('storeIconsInDatabaseSettingChanged event dispatched');
|
Log::info('StoreIconsInDatabaseSettingChanged event dispatched');
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -2,7 +2,7 @@
|
|||||||
|
|
||||||
namespace App\Listeners;
|
namespace App\Listeners;
|
||||||
|
|
||||||
use App\Events\storeIconsInDatabaseSettingChanged;
|
use App\Events\StoreIconsInDatabaseSettingChanged;
|
||||||
use App\Facades\IconStore;
|
use App\Facades\IconStore;
|
||||||
|
|
||||||
class ToggleIconReplicationToDatabase
|
class ToggleIconReplicationToDatabase
|
||||||
@ -15,7 +15,7 @@ class ToggleIconReplicationToDatabase
|
|||||||
/**
|
/**
|
||||||
* Handle the event.
|
* Handle the event.
|
||||||
*/
|
*/
|
||||||
public function handle(storeIconsInDatabaseSettingChanged $event) : void
|
public function handle(StoreIconsInDatabaseSettingChanged $event) : void
|
||||||
{
|
{
|
||||||
IconStore::setDatabaseReplication($event->newValue);
|
IconStore::setDatabaseReplication($event->newValue);
|
||||||
}
|
}
|
||||||
|
@ -5,7 +5,7 @@ namespace App\Providers;
|
|||||||
use App\Events\GroupDeleted;
|
use App\Events\GroupDeleted;
|
||||||
use App\Events\GroupDeleting;
|
use App\Events\GroupDeleting;
|
||||||
use App\Events\ScanForNewReleaseCalled;
|
use App\Events\ScanForNewReleaseCalled;
|
||||||
use App\Events\storeIconsInDatabaseSettingChanged;
|
use App\Events\StoreIconsInDatabaseSettingChanged;
|
||||||
use App\Events\TwoFAccountDeleted;
|
use App\Events\TwoFAccountDeleted;
|
||||||
use App\Events\VisitedByProxyUser;
|
use App\Events\VisitedByProxyUser;
|
||||||
use App\Listeners\Authentication\FailedLoginListener;
|
use App\Listeners\Authentication\FailedLoginListener;
|
||||||
@ -71,7 +71,7 @@ class EventServiceProvider extends ServiceProvider
|
|||||||
VisitedByProxyUser::class => [
|
VisitedByProxyUser::class => [
|
||||||
VisitedByProxyUserListener::class,
|
VisitedByProxyUserListener::class,
|
||||||
],
|
],
|
||||||
storeIconsInDatabaseSettingChanged::class => [
|
StoreIconsInDatabaseSettingChanged::class => [
|
||||||
ToggleIconReplicationToDatabase::class,
|
ToggleIconReplicationToDatabase::class,
|
||||||
],
|
],
|
||||||
];
|
];
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
|
|
||||||
namespace App\Services;
|
namespace App\Services;
|
||||||
|
|
||||||
use App\Events\storeIconsInDatabaseSettingChanged;
|
use App\Events\StoreIconsInDatabaseSettingChanged;
|
||||||
use App\Exceptions\DbEncryptionException;
|
use App\Exceptions\DbEncryptionException;
|
||||||
use App\Models\Option;
|
use App\Models\Option;
|
||||||
use Exception;
|
use Exception;
|
||||||
@ -79,7 +79,7 @@ class SettingService
|
|||||||
}
|
}
|
||||||
|
|
||||||
if ($setting === 'storeIconsInDatabase') {
|
if ($setting === 'storeIconsInDatabase') {
|
||||||
storeIconsInDatabaseSettingChanged::dispatch($value);
|
StoreIconsInDatabaseSettingChanged::dispatch($value);
|
||||||
}
|
}
|
||||||
|
|
||||||
Option::updateOrCreate(['key' => $setting], ['value' => $this->replaceBoolean($value)]);
|
Option::updateOrCreate(['key' => $setting], ['value' => $this->replaceBoolean($value)]);
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
|
|
||||||
namespace Tests\Feature\Services;
|
namespace Tests\Feature\Services;
|
||||||
|
|
||||||
use App\Events\storeIconsInDatabaseSettingChanged;
|
use App\Events\StoreIconsInDatabaseSettingChanged;
|
||||||
use App\Exceptions\FailedIconStoreDatabaseTogglingException;
|
use App\Exceptions\FailedIconStoreDatabaseTogglingException;
|
||||||
use App\Facades\IconStore;
|
use App\Facades\IconStore;
|
||||||
use App\Facades\Settings;
|
use App\Facades\Settings;
|
||||||
@ -370,12 +370,12 @@ class SettingServiceTest extends FeatureTestCase
|
|||||||
public function test_set_storeIconsInDatabase_setting_dispatches_storeIconsInDatabaseSettingChanged()
|
public function test_set_storeIconsInDatabase_setting_dispatches_storeIconsInDatabaseSettingChanged()
|
||||||
{
|
{
|
||||||
Event::fake([
|
Event::fake([
|
||||||
storeIconsInDatabaseSettingChanged::class,
|
StoreIconsInDatabaseSettingChanged::class,
|
||||||
]);
|
]);
|
||||||
|
|
||||||
Settings::set('storeIconsInDatabase', true);
|
Settings::set('storeIconsInDatabase', true);
|
||||||
|
|
||||||
Event::assertDispatched(storeIconsInDatabaseSettingChanged::class);
|
Event::assertDispatched(StoreIconsInDatabaseSettingChanged::class);
|
||||||
}
|
}
|
||||||
|
|
||||||
#[Test]
|
#[Test]
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
|
|
||||||
namespace Tests\Unit\Events;
|
namespace Tests\Unit\Events;
|
||||||
|
|
||||||
use App\Events\storeIconsInDatabaseSettingChanged;
|
use App\Events\StoreIconsInDatabaseSettingChanged;
|
||||||
use PHPUnit\Framework\Attributes\CoversClass;
|
use PHPUnit\Framework\Attributes\CoversClass;
|
||||||
use PHPUnit\Framework\Attributes\Test;
|
use PHPUnit\Framework\Attributes\Test;
|
||||||
use Tests\TestCase;
|
use Tests\TestCase;
|
||||||
@ -10,14 +10,14 @@ use Tests\TestCase;
|
|||||||
/**
|
/**
|
||||||
* storeIconsInDatabaseSettingChangedTest test class
|
* storeIconsInDatabaseSettingChangedTest test class
|
||||||
*/
|
*/
|
||||||
#[CoversClass(storeIconsInDatabaseSettingChanged::class)]
|
#[CoversClass(StoreIconsInDatabaseSettingChanged::class)]
|
||||||
class storeIconsInDatabaseSettingChangedTest extends TestCase
|
class storeIconsInDatabaseSettingChangedTest extends TestCase
|
||||||
{
|
{
|
||||||
#[Test]
|
#[Test]
|
||||||
public function test_event_constructor()
|
public function test_event_constructor()
|
||||||
{
|
{
|
||||||
$newValue = true;
|
$newValue = true;
|
||||||
$event = new storeIconsInDatabaseSettingChanged($newValue);
|
$event = new StoreIconsInDatabaseSettingChanged($newValue);
|
||||||
|
|
||||||
$this->assertSame($newValue, $event->newValue);
|
$this->assertSame($newValue, $event->newValue);
|
||||||
}
|
}
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
|
|
||||||
namespace Tests\Unit\Listeners;
|
namespace Tests\Unit\Listeners;
|
||||||
|
|
||||||
use App\Events\storeIconsInDatabaseSettingChanged;
|
use App\Events\StoreIconsInDatabaseSettingChanged;
|
||||||
use App\Listeners\ToggleIconReplicationToDatabase;
|
use App\Listeners\ToggleIconReplicationToDatabase;
|
||||||
use Illuminate\Support\Facades\Event;
|
use Illuminate\Support\Facades\Event;
|
||||||
use PHPUnit\Framework\Attributes\CoversClass;
|
use PHPUnit\Framework\Attributes\CoversClass;
|
||||||
@ -21,7 +21,7 @@ class ToggleIconReplicationToDatabaseTest extends TestCase
|
|||||||
Event::fake();
|
Event::fake();
|
||||||
|
|
||||||
Event::assertListening(
|
Event::assertListening(
|
||||||
storeIconsInDatabaseSettingChanged::class,
|
StoreIconsInDatabaseSettingChanged::class,
|
||||||
ToggleIconReplicationToDatabase::class
|
ToggleIconReplicationToDatabase::class
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user