Skip to content

Commit

Permalink
Simplify class_uses_recursive() uses (#24931)
Browse files Browse the repository at this point in the history
  • Loading branch information
staudenmeir authored and taylorotwell committed Jul 23, 2018
1 parent ca7126e commit eddbd6e
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -135,9 +135,7 @@ public function getQualifiedParentKeyName()
*/
public function throughParentSoftDeletes()
{
return in_array(SoftDeletes::class, class_uses_recursive(
get_class($this->throughParent)
));
return in_array(SoftDeletes::class, class_uses_recursive($this->throughParent));
}

/**
Expand Down
2 changes: 1 addition & 1 deletion src/Illuminate/Events/CallQueuedListener.php
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ public function handle(Container $container)
*/
protected function setJobInstanceIfNecessary(Job $job, $instance)
{
if (in_array(InteractsWithQueue::class, class_uses_recursive(get_class($instance)))) {
if (in_array(InteractsWithQueue::class, class_uses_recursive($instance))) {
$instance->setJob($job);
}

Expand Down
2 changes: 1 addition & 1 deletion src/Illuminate/Queue/CallQueuedHandler.php
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ protected function resolveHandler($job, $command)
*/
protected function setJobInstanceIfNecessary(Job $job, $instance)
{
if (in_array(InteractsWithQueue::class, class_uses_recursive(get_class($instance)))) {
if (in_array(InteractsWithQueue::class, class_uses_recursive($instance))) {
$instance->setJob($job);
}

Expand Down

0 comments on commit eddbd6e

Please sign in to comment.