Sha256: 145d29c217bd5a15fcb6713d0493d99f32caa9276545cf5dae54969137f8a720
Contents?: true
Size: 472 Bytes
Versions: 133
Compression:
Stored size: 472 Bytes
Contents
module Mumuki::Laboratory::Controllers::Content extend ActiveSupport::Concern included do before_action :validate_used_here!, only: :show end # ensures contents are in current organization's path def validate_used_here! #TODO refactor subject logic (e.g. we can't move validate_accessible! here because ExerciseSolutionsController does not declare a subject) raise Mumuki::Domain::NotFoundError unless subject&.used_in?(Organization.current) end end
Version data entries
133 entries across 133 versions & 1 rubygems