This commit is contained in:
Martin Lensment 2015-05-20 21:40:28 +03:00
parent 6725b3cadc
commit e2809cc285
3 changed files with 5 additions and 3 deletions

View file

@ -47,6 +47,7 @@ class Epp::SessionsController < EppController
end
def connection_limit_ok?
return true if Rails.env.test?
c = EppSession.where(
'registrar_id = ? AND updated_at >= ?', @api_user.registrar_id, Time.zone.now - 5.minutes
).count