Skip to content

Commit

Permalink
Fixed: Navigation can't be disabled
Browse files Browse the repository at this point in the history
  • Loading branch information
cannycookie committed Nov 22, 2024
1 parent 52189e4 commit 694eb8c
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/EmailTemplatesPlugin.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ class EmailTemplatesPlugin implements Plugin

public string $navigationGroup;

protected bool|Closure $navigation = true;
protected bool|Closure|null $navigation = null;

public static function make(): static
{
Expand All @@ -41,15 +41,15 @@ public function enableNavigation(bool|Closure $callback = true): static

public function shouldRegisterNavigation(): bool
{
return $this->evaluate($this->navigation) === true ?? config('filament-email-templates.navigation.enabled',
true);
return $this->evaluate($this->navigation) ?? config('filament-email-templates.navigation.enabled',true);
}

public function navigationGroup($navigationGroup): static
public function navigationGroup(string $navigationGroup): static
{
$this->navigationGroup = $navigationGroup;
return $this;
}


public function getNavigationGroup(): ?string
{
Expand Down

0 comments on commit 694eb8c

Please sign in to comment.