fixing bad ref in index