Delete/destroy function fixed