class WelcomeController < ApplicationController
  def index
    @yellow_jersey = Trip.group(:user).order('sum_distance_in_meter DESC').sum(:distance_in_meter)
  end
end

class WelcomeController < ApplicationController
  def index
    season = Season.default
    @yellow_jersey = Trip.where(trip_date: season.start_date..season.end_date).group(:user).order('sum_distance_in_meter DESC').sum(:distance_in_meter)
  end
end

Fix yellow jersey on homepage
Fix yellow jersey on homepage
