Skip to content

Commit

Permalink
Fix styling
Browse files Browse the repository at this point in the history
  • Loading branch information
bezhanSalleh authored and github-actions[bot] committed Sep 2, 2024
1 parent b074108 commit 22e1a44
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 16 deletions.
2 changes: 1 addition & 1 deletion bootstrap/app.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
use Orchestra\Testbench\Concerns\CreatesApplication;
use Orchestra\Testbench\Foundation\Application;

$basePathLocator = new class()
$basePathLocator = new class
{
use CreatesApplication;
};
Expand Down
6 changes: 3 additions & 3 deletions src/Commands/Concerns/CanManipulateFiles.php
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ protected function checkForCollision(array $paths): bool

protected function copyStubToApp(string $stub, string $targetPath, array $replacements = []): void
{
$filesystem = new Filesystem();
$filesystem = new Filesystem;

if (! $this->fileExists($stubPath = base_path("stubs/filament/{$stub}.stub"))) {
$stubPath = __DIR__ . "/../../../stubs/{$stub}.stub";
Expand All @@ -41,14 +41,14 @@ protected function copyStubToApp(string $stub, string $targetPath, array $replac

protected function fileExists(string $path): bool
{
$filesystem = new Filesystem();
$filesystem = new Filesystem;

return $filesystem->exists($path);
}

protected function writeFile(string $path, string $contents): void
{
$filesystem = new Filesystem();
$filesystem = new Filesystem;

$filesystem->ensureDirectoryExists(
(string) Str::of($path)
Expand Down
2 changes: 1 addition & 1 deletion src/FilamentShieldServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ public function packageRegistered(): void
parent::packageRegistered();

$this->app->scoped('filament-shield', function (): FilamentShield {
return new FilamentShield();
return new FilamentShield;
});
}

Expand Down
4 changes: 2 additions & 2 deletions src/Support/Utils.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ public static function isResourcePublished(): bool
{
$roleResourcePath = app_path((string) Str::of('Filament\\Resources\\Shield\\RoleResource.php')->replace('\\', '/'));

$filesystem = new Filesystem();
$filesystem = new Filesystem;

return (bool) $filesystem->exists($roleResourcePath);
}
Expand Down Expand Up @@ -252,7 +252,7 @@ public static function getPolicyPath(): string

protected static function isRolePolicyGenerated(): bool
{
$filesystem = new Filesystem();
$filesystem = new Filesystem;

return (bool) $filesystem->exists(app_path(static::getPolicyPath() . DIRECTORY_SEPARATOR . 'RolePolicy.php'));
}
Expand Down
12 changes: 3 additions & 9 deletions src/Traits/HasPageShield.php
Original file line number Diff line number Diff line change
Expand Up @@ -34,17 +34,11 @@ public function booted(): void
$this->afterBooted();
}

protected function beforeBooted(): void
{
}
protected function beforeBooted(): void {}

protected function afterBooted(): void
{
}
protected function afterBooted(): void {}

protected function beforeShieldRedirects(): void
{
}
protected function beforeShieldRedirects(): void {}

protected function getShieldRedirectPath(): string
{
Expand Down

0 comments on commit 22e1a44

Please sign in to comment.