small fix in case of main index