bottles: only try f.bottle.revision if it exists.

This commit is contained in:
Mike McQuaid 2013-07-04 11:23:47 +01:00
parent 9d12b917ec
commit 6c242ad4bb

View File

@ -7,7 +7,7 @@ require 'extend/ARGV'
def bottle_filename f, bottle_revision=nil
name = f.name.downcase
version = f.stable.version
bottle_revision ||= f.bottle.revision.to_i
bottle_revision ||= f.bottle.revision.to_i if f.bottle
"#{name}-#{version}#{bottle_native_suffix(bottle_revision)}"
end