Fixed Map.getIndex(). This fixes #18.