Fix Style/GuardClause in PreviewCard (#35525)

This commit is contained in:
Matt Jankowski 2025-07-28 04:40:37 -04:00 committed by GitHub
parent e183d7dd9a
commit 63daf6b317
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -170,10 +170,9 @@ class PreviewCard < ApplicationRecord
private
def serialized_authors
if author_name? || author_url? || author_account_id?
PreviewCard::Author
.new(self)
end
return unless author_name? || author_url? || author_account_id?
PreviewCard::Author.new(self)
end
def extract_dimensions