Skip to content

Commit

Permalink
Fix styling
Browse files Browse the repository at this point in the history
  • Loading branch information
markvaneijk authored and github-actions[bot] committed Apr 20, 2024
1 parent 3274485 commit c86ce7a
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 6 deletions.
2 changes: 1 addition & 1 deletion config/trailing-slash.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,6 @@

// Execute middleware only on these methods
'methods' => [
'GET', 'HEAD', 'OPTIONS'
'GET', 'HEAD', 'OPTIONS',
],
];
2 changes: 1 addition & 1 deletion src/Middleware/EnsureUrlsWithTrailingSlash.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ class EnsureUrlsWithTrailingSlash extends TrailingSlashMiddleware
{
public function handle($request, Closure $next)
{
if(! $this->shouldHandle($request, shouldHaveTrailingSlash: true)) {
if (! $this->shouldHandle($request, shouldHaveTrailingSlash: true)) {
return $next($request);
}

Expand Down
2 changes: 1 addition & 1 deletion src/Middleware/EnsureUrlsWithoutTrailingSlash.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ class EnsureUrlsWithoutTrailingSlash extends TrailingSlashMiddleware
{
public function handle($request, Closure $next)
{
if(! $this->shouldHandle($request, shouldHaveTrailingSlash: false)) {
if (! $this->shouldHandle($request, shouldHaveTrailingSlash: false)) {
return $next($request);
}

Expand Down
5 changes: 2 additions & 3 deletions src/Middleware/TrailingSlashMiddleware.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

namespace Vormkracht10\TrailingSlash\Middleware;

use Closure;
use Illuminate\Http\Request;

class TrailingSlashMiddleware
Expand All @@ -15,7 +14,7 @@ public function shouldHandle(Request $request, $shouldHaveTrailingSlash = true)
return false;
}

if($this->getParsedUrl($request)['path'] === '/') {
if ($this->getParsedUrl($request)['path'] === '/') {
return false;
}

Expand Down Expand Up @@ -50,7 +49,7 @@ public function shouldHandle(Request $request, $shouldHaveTrailingSlash = true)

public function getParsedUrl(Request $request)
{
if($this->parsedUrl) {
if ($this->parsedUrl) {
return $this->parsedUrl;
}

Expand Down

0 comments on commit c86ce7a

Please sign in to comment.