Method: Html2rss::ItemExtractors::Href#get

Defined in:
lib/html2rss/item_extractors/href.rb

#getString

Retrieves and returns the normalized absolute URL.

Returns:

  • (String)

    The absolute URL.

[View source]

44
45
46
47
48
49
# File 'lib/html2rss/item_extractors/href.rb', line 44

def get
  return nil unless @href

  sanitized_href = Html2rss::Utils.sanitize_url(@href)
  Html2rss::Utils.build_absolute_url_from_relative(sanitized_href, @options.channel.url)
end