Fixed a bug where deletes from nonexisting keys throws errors