fixed panic when no cmd is passed