public function status(string $status): Member
    {
        if (!in_array($status, ['subscribed', 'unsubscribed', 'cleaned', 'pending'])) {
            throw new \InvalidArgumentException('Status must be subscribed, unsubscribed, cleaned or pending');
        }
        $this->parameters['status'] = $status;
        return $this;
    }
public function status(string $status): Member
    {
        if (!in_array($status, ['subscribed', 'unsubscribed', 'cleaned', 'pending'])) {
            throw new \InvalidArgumentException('Status must be subscribed, unsubscribed, cleaned or pending');
        }
        $this->parameters['status'] = $status;
        return $this;
    }
public function status ( string $ status ) : Member { if ( ! in_array ( $ status , [ 'subscribed' , 'unsubscribed' , 'cleaned' , 'pending' ] ) ) { throw new \ InvalidArgumentException ( 'Status must be subscribed, unsubscribed, cleaned or pending' ) ; } $ this -> parameters [ 'status' ] = $ status ; return $ this ; }
Note this doesn't affect status_if_new, therefore it's not possible to add a new member as unsubscribed or cleaned
Note this doesn t affect status_if_new therefore it s not possible to add a new member as unsubscribed or cleaned