Removed an unnecessary O(n) search when unloading a document given its key.