Fixed indexing issue.