Resolved the index issue