lib/custom_facts/util/collection.rb
# Return a fact by name.
Return a fact by name.
Return a fact by name .
def fact(name)
        name = canonicalize(name)
        load(name) unless @facts[name]
        internal_loader.load_all unless @facts[name]
        if @facts.empty?
          LegacyFacter.warnonce("No facts loaded from #{internal_loader.search_path.join(File::PATH_SEPARATOR)}")
        end
        @facts[name]
      end
def fact ( name ) name = canonicalize ( name ) load ( name ) unless @facts [ name ] internal_loader . load_all unless @facts [ name ] if @facts . empty? LegacyFacter . warnonce ( "No facts loaded from #{internal_loader.search_path.join(File::PATH_SEPARATOR)}" ) end @facts [ name ] end
Return a fact by name.
Return a fact by name .
# Try to load the fact if necessary # Try HARDER
name