deviantart: return nil on failure instead of ""
was also part of eba6440b8b
This commit is contained in:
@@ -106,7 +106,7 @@ module Sources
|
|||||||
elsif deviation_id.present?
|
elsif deviation_id.present?
|
||||||
page_url_from_image_url
|
page_url_from_image_url
|
||||||
else
|
else
|
||||||
""
|
nil
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
@@ -123,7 +123,7 @@ module Sources
|
|||||||
end
|
end
|
||||||
|
|
||||||
def profile_url
|
def profile_url
|
||||||
return "" if artist_name.blank?
|
return nil if artist_name.blank?
|
||||||
"https://www.deviantart.com/#{artist_name.downcase}"
|
"https://www.deviantart.com/#{artist_name.downcase}"
|
||||||
end
|
end
|
||||||
|
|
||||||
@@ -135,7 +135,7 @@ module Sources
|
|||||||
elsif api_metadata.present?
|
elsif api_metadata.present?
|
||||||
api_metadata.dig(:author, :username)
|
api_metadata.dig(:author, :username)
|
||||||
else
|
else
|
||||||
""
|
nil
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user