From eef4559379573d9921a4786ab20d25529fd728b7 Mon Sep 17 00:00:00 2001 From: Ash Monsh Date: Sat, 16 Sep 2023 00:03:34 +0300 Subject: [PATCH] fix tag not found --- routes/web.php | 4 ++-- src/Http/Livewire/{LibrarTag.php => LibraryTag.php} | 4 ++-- src/Http/Livewire/Tags.php | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) rename src/Http/Livewire/{LibrarTag.php => LibraryTag.php} (95%) diff --git a/routes/web.php b/routes/web.php index 229db0d..b1291a4 100644 --- a/routes/web.php +++ b/routes/web.php @@ -2,7 +2,7 @@ use Illuminate\Support\Facades\Route; use LaraZeus\Sky\Http\Livewire\Faq; -use LaraZeus\Sky\Http\Livewire\LibrarTag; +use LaraZeus\Sky\Http\Livewire\LibraryTag; use LaraZeus\Sky\Http\Livewire\Library; use LaraZeus\Sky\Http\Livewire\LibraryItem; use LaraZeus\Sky\Http\Livewire\Page; @@ -26,7 +26,7 @@ if (SkyPlugin::get()->hasLibraryResource()) { Route::prefix(SkyPlugin::get()->getUriPrefix()['library'])->group(function () { Route::get('/', Library::class)->name('library'); - Route::get('/tag/{slug}', LibrarTag::class)->name('library.tag'); + Route::get('/tag/{slug}', LibraryTag::class)->name('library.tag'); Route::get('/{slug}', LibraryItem::class)->name('library.item'); }); } diff --git a/src/Http/Livewire/LibrarTag.php b/src/Http/Livewire/LibraryTag.php similarity index 95% rename from src/Http/Livewire/LibrarTag.php rename to src/Http/Livewire/LibraryTag.php index af0b898..c259a56 100644 --- a/src/Http/Livewire/LibrarTag.php +++ b/src/Http/Livewire/LibraryTag.php @@ -7,9 +7,9 @@ use LaraZeus\Sky\SkyPlugin; use Livewire\Component; -class LibrarTag extends Component +class LibraryTag extends Component { - public Tag $tag; + public ?Tag $tag; public function mount(string $slug): void { diff --git a/src/Http/Livewire/Tags.php b/src/Http/Livewire/Tags.php index 6ca728d..6ce7411 100644 --- a/src/Http/Livewire/Tags.php +++ b/src/Http/Livewire/Tags.php @@ -13,7 +13,7 @@ class Tags extends Component public string $slug; - public Tag $tag; + public ?Tag $tag; public function mount(string $type, string $slug): void {