diff options
| author | Jack Nagel | 2014-04-05 17:41:37 -0500 |
|---|---|---|
| committer | Jack Nagel | 2014-04-05 17:41:37 -0500 |
| commit | dd6e8c7186235cc3e718e92d1b7dfc842e6c373a (patch) | |
| tree | c1a7666d1201e8a0567ae0b7ef967f59358460c7 /Library | |
| parent | 109fff1b0f64351e8cdb2c7fd4bb833ce6535c79 (diff) | |
| download | homebrew-dd6e8c7186235cc3e718e92d1b7dfc842e6c373a.tar.bz2 | |
Combine conditional branches that do the same thing
Diffstat (limited to 'Library')
| -rw-r--r-- | Library/Homebrew/formulary.rb | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/Library/Homebrew/formulary.rb b/Library/Homebrew/formulary.rb index c2f977c2e..34e40fa23 100644 --- a/Library/Homebrew/formulary.rb +++ b/Library/Homebrew/formulary.rb @@ -176,11 +176,9 @@ class Formulary # name appears to be a tapped formula, so we don't munge it # in order to provide a useful error message when require fails. f = TapLoader.new(name_or_path) - elsif name_or_path.include? "/" + elsif name_or_path.include?("/") || File.extname(name_or_path) == ".rb" # If name was a path or mapped to a cached formula f = FromPathLoader.new(name_or_path) - elsif File.extname(name_or_path) == ".rb" - f = FromPathLoader.new(name_or_path) else f = StandardLoader.new(name_or_path) end |
