fixes indexOld (not closed div)