correctly delete values