improved delete hashmap