Skip to content

Commit

Permalink
chore: fix php-cs
Browse files Browse the repository at this point in the history
  • Loading branch information
albertcht committed Dec 2, 2024
1 parent 86d84cb commit 551ea7f
Showing 1 changed file with 6 additions and 11 deletions.
17 changes: 6 additions & 11 deletions src/support/src/Testing/Fakes/BusFake.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
// use Illuminate\Bus\PendingBatch;
// use Illuminate\Contracts\Bus\QueueingDispatcher;
// use Illuminate\Support\Arr;
// use Illuminate\Support\Collection;
// use Hyperf\Collection\Collection;
// use Illuminate\Support\Traits\ReflectsClosures;
use Hyperf\Collection\Arr;
use Hyperf\Collection\Collection;
Expand Down Expand Up @@ -537,9 +537,8 @@ public function dispatch(mixed $command): mixed
{
if ($this->shouldFakeJob($command)) {
return $this->commands[get_class($command)][] = $this->getCommandRepresentation($command);
} else {
return $this->dispatcher->dispatch($command);
}
return $this->dispatcher->dispatch($command);
}

/**
Expand All @@ -551,9 +550,8 @@ public function dispatchSync(mixed $command, mixed $handler = null): mixed
{
if ($this->shouldFakeJob($command)) {
return $this->commandsSync[get_class($command)][] = $this->getCommandRepresentation($command);
} else {
return $this->dispatcher->dispatchSync($command, $handler);
}
return $this->dispatcher->dispatchSync($command, $handler);
}

/**
Expand All @@ -563,9 +561,8 @@ public function dispatchNow(mixed $command, mixed $handler = null): mixed
{
if ($this->shouldFakeJob($command)) {
return $this->commands[get_class($command)][] = $this->getCommandRepresentation($command);
} else {
return $this->dispatcher->dispatchNow($command, $handler);
}
return $this->dispatcher->dispatchNow($command, $handler);
}

/**
Expand All @@ -575,9 +572,8 @@ public function dispatchToQueue(mixed $command): mixed
{
if ($this->shouldFakeJob($command)) {
return $this->commands[get_class($command)][] = $this->getCommandRepresentation($command);
} else {
return $this->dispatcher->dispatchToQueue($command);
}
return $this->dispatcher->dispatchToQueue($command);
}

/**
Expand All @@ -587,9 +583,8 @@ public function dispatchAfterResponse(mixed $command): mixed
{
if ($this->shouldFakeJob($command)) {
return $this->commandsAfterResponse[get_class($command)][] = $this->getCommandRepresentation($command);
} else {
return $this->dispatcher->dispatch($command);
}
return $this->dispatcher->dispatch($command);
}

/**
Expand Down

0 comments on commit 551ea7f

Please sign in to comment.