changed Array#index() to Array#rindex(), seems to fix dupe break