Fixing indexation bug