shortened calculate_upvotes method