Updated Command

fixed deprecated methods