mirror of
https://github.com/dkam/paapi.git
synced 2025-12-28 07:04:53 +00:00
Pluck out languages
This commit is contained in:
@@ -77,6 +77,18 @@ module Paapi
|
|||||||
contributors_of 'Publisher'
|
contributors_of 'Publisher'
|
||||||
end
|
end
|
||||||
|
|
||||||
|
def languages
|
||||||
|
get(%w{ItemInfo ContentInfo Languages DisplayValues})
|
||||||
|
end
|
||||||
|
|
||||||
|
def original_language
|
||||||
|
language&.find {|l| l['Type'] == 'Original Language' }&.dig('DisplayValue')
|
||||||
|
end
|
||||||
|
|
||||||
|
def published_language
|
||||||
|
language&.find {|l| l['Type'] == 'Published' }&.dig('DisplayValue')
|
||||||
|
end
|
||||||
|
|
||||||
def eans
|
def eans
|
||||||
get(%w{ItemInfo ExternalIds EANs DisplayValues})
|
get(%w{ItemInfo ExternalIds EANs DisplayValues})
|
||||||
end
|
end
|
||||||
|
|||||||
Reference in New Issue
Block a user