lib/puppet/parser/compiler.rb
# Return the node's environment.
Return the node's environment.
Return the node ' s environment .
def environment
    unless defined?(@environment)
      unless node.environment.is_a? Puppet::Node::Environment
        raise Puppet::DevError, "node #{node} has an invalid environment!"
      end
      @environment = node.environment
    end
    Puppet::Node::Environment.current = @environment
    @environment
  end
def environment unless defined? ( @environment ) unless node . environment . is_a? Puppet :: Node :: Environment raise Puppet :: DevError , "node #{node} has an invalid environment!" end @environment = node . environment end Puppet :: Node :: Environment . current = @environment @environment end
Return the node's environment.
Return the node ' s environment .