Revert to threaded implementation with hashmap check