Check whether anonymous id or user id is given (#49)