Module: Ixtlan::Gettext::Controller

Defined in:
lib/ixtlan/gettext/controller.rb

Instance Method Summary collapse

Instance Method Details

#flushObject



5
6
7
8
9
10
11
12
13
# File 'lib/ixtlan/gettext/controller.rb', line 5

def flush
  # only for localhost
  if request.remote_ip == '127.0.0.1'
    Rails.application.config.gettext.flush_caches
    head :ok
  else
    head :not_found
  end
end