Fixed one littel bug in getIndexTo save and the files that use it