cask/artifact/relocated: tweak syntax.

This commit is contained in:
Mike McQuaid 2022-10-25 09:00:54 +01:00 committed by GitHub
parent 237a4181c0
commit 4e3a21b380
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -52,7 +52,7 @@ module Cask
@source_string = source.to_s
@target_string = target.to_s
base_path = cask.staged_path
base_path = base_path.join(cask.url.only_path) if cask.url && cask.url.only_path.present?
base_path = base_path.join(cask.url.only_path) if cask.url&.only_path.present?
source = base_path.join(source)
@source = source
target ||= source.basename