fixed bug with destroy command