Fixed some indexes that were invalid