```ruby
class DayController < ApplicationController
  get '/:date?', authentication: true do
    @date_string = params[:date] || Date.today.to_s
    date = Date.parse(@date_string)
    @lists = ListRepository.find_by_date(date)

    slim :'day/day'
  end

  post '/:date/list', authentication: true do
    ListRepository.create_empty(params[:title], params[:date])
  end

  private

  def get_date(params)
    date_string = params[:date] || Date.today.to_s
    Date.parse(date_string)
  end
end
```

Add endpoints for deleting lists, adding and removing items to/from a list
user
```ruby
class DayController < ApplicationController
  get '/:date?', authentication: true do |date_string|
    @date_string = date_string || Date.today.to_s
    date = Date.parse(@date_string)
    @lists = List.find_by_date(date, user_id)

    slim :'day/index'
  end

  post '/:date/list', authentication: true do |date|
    List.create_empty(params[:title], date, user_id)
    redirect to "/#{date}"
  end

  delete '/:date/list/:id', authentication: true do |date, id|
    List.delete_by_id(id, user_id)
    redirect to "/#{date}"
  end

  post '/:date/list/:id', authentication: true do |date, id|
    list = List.find_by_id(id, user_id)
    list.add(params[:text]) if list

    redirect to "/#{date}"
  end

  delete '/:date/list/:id/:item_id', authentication: true do |date, list_id, item_id|
    list = List.find_by_id(list_id, user_id)
    list.remove(item_id) if list

    redirect to "/#{date}"
  end
end
```
assistant