Fixed error with command method