Created
November 25, 2018 19:38
-
-
Save talum/94cb3083d370d5f32ed964eec06a094f to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Lesson < Curriculum | |
belongs_to :canonical_material, class_name: CourseWork::CanonicalMaterial | |
has_one :lab, foreign_key: :curriculum_id | |
def lab? | |
if $rollout.active?(:remove_content) | |
canonical_material.lab? | |
else | |
!!lab | |
end | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment