Unify is clamed on Invite like we do on Subscriber
This commit is contained in:
@@ -42,7 +42,7 @@ class SignupController extends Controller
|
||||
|
||||
$invite = Invite::where('code', '=', $code)->first();
|
||||
|
||||
if (!$invite || $invite->claimed()) {
|
||||
if (!$invite || $invite->is_claimed) {
|
||||
throw new BadRequestHttpException();
|
||||
}
|
||||
|
||||
@@ -67,7 +67,7 @@ class SignupController extends Controller
|
||||
|
||||
$invite = Invite::where('code', '=', $code)->first();
|
||||
|
||||
if (!$invite || $invite->claimed()) {
|
||||
if (!$invite || $invite->is_claimed) {
|
||||
throw new BadRequestHttpException();
|
||||
}
|
||||
|
||||
|
||||
@@ -60,7 +60,7 @@ class Invite extends Model
|
||||
*
|
||||
* @return bool
|
||||
*/
|
||||
public function claimed()
|
||||
public function getIsClaimedAttribute()
|
||||
{
|
||||
return $this->claimed_at !== null;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user