minor unknown index bug fixed