Skip to content

Commit

Permalink
Swapped and for Laravel 5.3
Browse files Browse the repository at this point in the history
  • Loading branch information
Gerhard Theunissen committed Nov 11, 2016
1 parent eb0e0f9 commit 8e426b9
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/LaraPlans/SubscriptionAbility.php
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ public function enabled($feature)
public function value($feature, $default = null)
{
$feature = $this->subscription->plan->features->first(function ($key, $value) use ($feature) {
return $value->code === $feature;
return $key->code === $feature;
});

if (is_null($feature))
Expand Down
2 changes: 1 addition & 1 deletion src/LaraPlans/Traits/PlanSubscriber.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ public function subscription($name = 'default')
return $value->created_at->getTimestamp();
})
->first(function ($key, $value) use ($name) {
return $value->name === $name;
return $key->name === $name;
});
}

Expand Down

0 comments on commit 8e426b9

Please sign in to comment.