destroy command refactor