Checking command's type