class Franklin::TypeFilter
Attributes
type[R]
Public Class Methods
new(type)
click to toggle source
# File lib/franklin/type_filter.rb, line 3 def initialize(type) @type = type end
Public Instance Methods
perform(results)
click to toggle source
# File lib/franklin/type_filter.rb, line 7 def perform(results) return results unless type results.dup.keep_if { |item, _availability| item.format.casecmp(type).zero? } end