app/Models/Traits/Subscribable.php
/**
     * Remove a subscription from this record for the given user.
     *
     * @param $user mixed - If null will use currently logged in user.
     * @throws
     */
Remove a subscription from this record for the given user.
@param $user mixed - If null will use currently logged in user.
@throws
Remove a subscription from this record for the given user . @param $user mixed - If null will use currently logged in user . @throws
public function unsubscribe($user = null)
    {
        if (null === $user) {
            $user = auth()->user();
        }
        $subscription = $this->subscriptions()->where('user_id', '=', $user->id)->first();
        if (! $subscription) {
            return;
        }
        $subscription->delete();
    }
public function unsubscribe ( $ user = null ) { if ( null === $ user ) { $ user = auth ( ) -> user ( ) ; } $ subscription = $ this -> subscriptions ( ) -> where ( 'user_id' , '=' , $ user -> id ) -> first ( ) ; if ( ! $ subscription ) { return ; } $ subscription -> delete ( ) ; }
Remove a subscription from this record for the given user.
Remove a subscription from this record for the given user .