moved method to index