Fixed IndexMap implementation.