adding a check for accessible ES to the _prep_index. If not there, scripts exit.