Sha256: 034590e5fa2bbe01ecd3283bcb5c2b15853bf0ed7c36166dc81ba9e58c3a6b2b
Contents?: true
Size: 407 Bytes
Versions: 10
Compression:
Stored size: 407 Bytes
Contents
# frozen_string_literal: true module UltimateLyrics class Provider class UrlFormat common_constructor :node def apply(value) replace_chars.inject(value) { |a, e| a.gsub(e, with) } end def replace_chars ::CGI.unescapeHTML(node.attribute('replace').text).each_char.to_a end def with node.attribute('with').text end end end end
Version data entries
10 entries across 10 versions & 2 rubygems