Sha256: 6d669db5e79825e749a7aa3d0499dbfae723f9e2177f4387d58d9e8560a50a5d
Contents?: true
Size: 384 Bytes
Versions: 3
Compression:
Stored size: 384 Bytes
Contents
class ApplicationController < ActionController::Base protect_from_forgery before_filter :slowajaxload ajax_respond :pagination => "", :render => { :layout => "ajax" } def slowajaxload if (request.GET[:pagination] || params[:pagination]) && Rails.env == "test" delay = 0 delay = ENV['AJAX_DELAY'] if ENV['AJAX_DELAY'] sleep(delay.to_f) end end end
Version data entries
3 entries across 2 versions & 1 rubygems