From 0c180b521c402574c6424bd8a5723df0ec4ddf3a Mon Sep 17 00:00:00 2001 From: lllusion3469 <31420484+lllusion3469@users.noreply.github.com> Date: Mon, 11 May 2020 12:09:44 +0200 Subject: [PATCH] deviantart: avoid download api call if not downloadable because it's included in api_response which is part of /source.json --- app/logical/sources/strategies/deviant_art.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/logical/sources/strategies/deviant_art.rb b/app/logical/sources/strategies/deviant_art.rb index c11c69e61..788f7fa36 100644 --- a/app/logical/sources/strategies/deviant_art.rb +++ b/app/logical/sources/strategies/deviant_art.rb @@ -297,7 +297,7 @@ module Sources memoize :api_metadata def api_download - return {} if uuid.nil? + return {} unless uuid.present? && api_deviation[:is_downloadable] api_client.download(uuid) end memoize :api_download