Skip to content

Commit

Permalink
fix ->isEnabled()
Browse files Browse the repository at this point in the history
  • Loading branch information
3x1io committed Sep 17, 2024
1 parent 0ca31d9 commit 90b5f80
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
2 changes: 1 addition & 1 deletion module.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
"icon": "heroicon-c-receipt-percent",
"placeholder": "https://raw.githubusercontent.com/tomatophp/filament-invoices/master/arts/3x1io-tomato-invoices.jpg",
"type": "plugin",
"version": "v1.0.3",
"version": "v1.0.4",
"github" : "https://github.com/tomatophp/filament-invoices",
"docs" : "https://github.com/tomatophp/filament-invoices"
}
6 changes: 2 additions & 4 deletions src/FilamentInvoicesPlugin.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,8 @@ public function getId(): string

public function register(Panel $panel): void
{
if(class_exists(Module::class)){
if(\Nwidart\Modules\Facades\Module::find('FilamentInvoices')?->isEnabled()){
$this->isActive = true;
}
if(class_exists(Module::class) && \Nwidart\Modules\Facades\Module::find('FilamentInvoices')?->isEnabled()){
$this->isActive = true;
}
else {
$this->isActive = true;
Expand Down

0 comments on commit 90b5f80

Please sign in to comment.