Moved upvote method from controller to model