Commit 771c0b83 authored by AliSoftware's avatar AliSoftware

[Command::Cache] fix segiddins nitpicking ;)

parent 7bc3d6bc
...@@ -31,7 +31,8 @@ module Pod ...@@ -31,7 +31,8 @@ module Pod
end end
def run def run
if @pod_name.nil? # && @wipe_all if @pod_name.nil?
# Note: at that point, @wipe_all is always true (thanks to `validate!`)
# Remove all # Remove all
clear_cache clear_cache
else else
......
...@@ -55,7 +55,7 @@ module Pod ...@@ -55,7 +55,7 @@ module Pod
spec_paths = specs_dir.find.select { |f| f.fnmatch('*.podspec.json') } spec_paths = specs_dir.find.select { |f| f.fnmatch('*.podspec.json') }
spec_paths.reduce({}) do |hash, spec_path| spec_paths.reduce({}) do |hash, spec_path|
spec = Specification.from_file(spec_path) spec = Specification.from_file(spec_path)
hash[spec.name] = [] if hash[spec.name].nil? hash[spec.name] ||= []
is_release = spec_path.to_s.start_with?(release_specs_dir.to_s) is_release = spec_path.to_s.start_with?(release_specs_dir.to_s)
request = Downloader::Request.new(:spec => spec, :released => is_release) request = Downloader::Request.new(:spec => spec, :released => is_release)
hash[spec.name] << { hash[spec.name] << {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment