fixed the bug about Invalid CMD