class Ability
  include CanCan::Ability

  def initialize(user)
    user ||= User.new
    can :update,                     Club,   :user_id => user.id
    can [ :create, :edit, :update ], Course, :club_id => user.clubs.first.id # TODO: Figure out how to restrict to course_id in user.clubs.map(&:id)
  end
end

class Ability
  include CanCan::Ability

  def initialize(user)
    user ||= User.new

    can :update, Club, :user_id => user.id

    can [ :create, :edit, :update ], Course do |course|
      course.user == user
    end

    can :create, Lesson do |lesson|
      lesson.user == user
    end
  end
end

Update Ability for Lesson create
Update Ability for Lesson create

Update the Ability model to ensure that the permissions are parsed for
creating a Lesson.
