Module RSS::Atom::DuplicateLinkChecker
In: lib/rss/atom.rb

Methods

Public Instance methods

[Source]

     # File lib/rss/atom.rb, line 193
193:       def validate_duplicate_links(links)
194:         link_infos = {}
195:         links.each do |link|
196:           rel = link.rel || "alternate"
197:           next unless rel == "alternate"
198:           key = [link.hreflang, link.type]
199:           if link_infos.has_key?(key)
200:             raise TooMuchTagError.new("link", tag_name)
201:           end
202:           link_infos[key] = true
203:         end
204:       end

[Validate]