Update average rating correctly