class ViewModel::AccessControl::Tree::Node

def validate_root!(view, context)

def validate_root!(view, context)
  if self.class.requires_root? && !context.root?
    raise RuntimeError.new("AccessControl instance for #{view.class.view_name} node requires root context but was visited in owned context.")
  end
end