fixed; index bug