Skip to content

Commit cf7848a

Browse files
vraravamMikeMcQuaid
andcommitted
Use simpler 'if-present' syntax instead of 'unless-nil' construct
Co-authored-by: Mike McQuaid <[email protected]>
1 parent fdee345 commit cf7848a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Library/Homebrew/cask/cask_loader.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -367,7 +367,7 @@ def load(config:)
367367
end
368368
desc json_cask[:desc]
369369
homepage json_cask[:homepage]
370-
login_items json_cask[:login_items] unless json_cask[:login_items].nil?
370+
login_items json_cask[:login_items] if json_cask[:login_items].present?
371371

372372
if (deprecation_date = json_cask[:deprecation_date].presence)
373373
reason = DeprecateDisable.to_reason_string_or_symbol json_cask[:deprecation_reason], type: :cask

0 commit comments

Comments
 (0)