Fixed the ArrayOutofBoundException in RecommenderClass