public function hashUserPasswordProperty(?int $cost = null) : string
    {
        if (!isset($this->password)) {
            throw new NullValueException('Password property not set on this object');
        }

        return bcrypt($this->password, ['rounds' => $this->getPasswordCost($cost)]);
    }
public function hashUserPasswordProperty(?int $cost = null) : string
    {
        if (!isset($this->password)) {
            throw new NullValueException('Password property not set on this object');
        }

        return bcrypt($this->password, ['rounds' => $this->getPasswordCost($cost)]);
    }
public function hashUserPasswordProperty ( ? int $ cost = null ) : string { if ( ! isset ( $ this -> password ) ) { throw new NullValueException ( 'Password property not set on this object' ) ; } return bcrypt ( $ this -> password , [ 'rounds' => $ this -> getPasswordCost ( $ cost ) ] ) ; }
Hash users password when property 'password' is set

@param int|null $cost
@return string
@throws \Laranix\Support\Exception\NullValueException
Hash users password when property password is set