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