add source + rewrite strategy for pawoo

This commit is contained in:
r888888888
2017-04-17 14:15:05 -07:00
parent 9718c6e107
commit b053a2d783
10 changed files with 176 additions and 2 deletions

View File

@@ -0,0 +1,25 @@
module Sources::Strategies
class Pawoo < Base
attr_reader :image_urls
def self.url_match?(url)
PawooApiClient::Status.is_match?(url)
end
def site_name
"Pawoo"
end
def get
response = PawooApiClient.new.get_status(url)
@artist_name = response.account_name
@profile_url = response.account_profile_url
@image_url = response.image_urls.first
@image_urls = response.image_urls
end
def normalizable_for_artist_finder?
true
end
end
end