mirror of
https://github.com/dkam/paapi.git
synced 2025-12-28 15:14:52 +00:00
Use RoleType with lower case role, rather than Role with capitalized role. Fixes #6
This commit is contained in:
@@ -54,8 +54,8 @@ module Paapi
|
||||
end
|
||||
|
||||
def contributors_of(kind)
|
||||
kind = kind.to_s.gsub(/([[:alpha:]]+)/) { |w| w.capitalize }
|
||||
contributors.select { |e| e['Role'] == kind }&.map { |e| e.dig('Name') }&.reject {|n| n.to_s.empty?}
|
||||
kind = kind.to_s.gsub(/([[:alpha:]]+)/) { |w| w.downcase }
|
||||
contributors.select { |e| e['RoleType'] == kind }&.map { |e| e.dig('Name') }&.reject {|n| n.to_s.empty?}
|
||||
end
|
||||
|
||||
def actors
|
||||
|
||||
Reference in New Issue
Block a user