Skip to content
Snippets Groups Projects
Commit 34fc227f authored by Jack Nagel's avatar Jack Nagel
Browse files

Get rid of StandardLoader class

parent b7ca3e33
No related branches found
No related tags found
No related merge requests found
......@@ -102,13 +102,6 @@ class Formulary
end
end
# Loads formulae from Homebrew's provided Library
class StandardLoader < FormulaLoader
def initialize name, path=Formula.path(name)
super
end
end
class AliasLoader < FormulaLoader
def initialize alias_path
path = alias_path.resolved_path
......@@ -202,7 +195,7 @@ class Formulary
formula_with_that_name = Formula.path(ref)
if formula_with_that_name.file?
return StandardLoader.new(ref, formula_with_that_name)
return FormulaLoader.new(ref, formula_with_that_name)
end
possible_alias = Pathname.new("#{HOMEBREW_LIBRARY}/Aliases/#{ref}")
......@@ -212,9 +205,9 @@ class Formulary
possible_cached_formula = Pathname.new("#{HOMEBREW_CACHE_FORMULA}/#{ref}.rb")
if possible_cached_formula.file?
return StandardLoader.new(ref, possible_cached_formula)
return FormulaLoader.new(ref, possible_cached_formula)
end
return StandardLoader.new(ref)
return FormulaLoader.new(ref, Formula.path(ref))
end
end
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment