fixed getDeadline and update CommandType