Sha256: e0bda9b4a432fab1fb5ae743845ebfccb27b65c6c02475fbdc93183d175d8258
Contents?: true
Size: 516 Bytes
Versions: 18
Compression:
Stored size: 516 Bytes
Contents
module GreenButtonData module Relations ## # Extracts related URLs from an Entry # # ==== Arguments # # * +entry+ - An instance of GreenButtonData::Parser::Entry def construct_related_urls(entry) related_urls = {} entry.related.each do |related_url| match_data = /\/(\w+)(\/(\d+))*$/.match(related_url) unless match_data.nil? related_urls[:"#{match_data[1].underscore}"] = related_url end end related_urls end end end
Version data entries
18 entries across 18 versions & 1 rubygems