Fixed wrong iteration variable check