Class: Purgeable::Client

Inherits:
Object
  • Object
show all
Defined in:
lib/purgeable/client.rb

Instance Method Summary collapse

Instance Method Details

#purge(urls) ⇒ Object



4
5
6
7
8
9
10
# File 'lib/purgeable/client.rb', line 4

def purge(urls)
  if urls.is_a?(String)
    cache_locations_for(urls).map{ |location| perform_purge(location, urls) }
  elsif urls.is_a?(Array)
    urls.map{ |url| purge(url) }
  end
end