Exception: CommandTower::Errors::Auth::SignupIpRateLimitError

Inherits:
CommandTower::Errors::ApplicationError show all
Defined in:
app/errors/command_tower/errors/auth/signup_ip_rate_limit_error.rb

Instance Attribute Summary

Attributes inherited from CommandTower::Errors::ApplicationError

#cause, #details

Instance Method Summary collapse

Methods inherited from CommandTower::Errors::ApplicationError

#retryable?

Constructor Details

#initialize(retry_after_seconds: nil) ⇒ SignupIpRateLimitError

Returns a new instance of SignupIpRateLimitError.



7
8
9
# File 'app/errors/command_tower/errors/auth/signup_ip_rate_limit_error.rb', line 7

def initialize(retry_after_seconds: nil)
  super(details: retry_after_seconds ? { retry_after_seconds: retry_after_seconds } : nil)
end

Instance Method Details

#codeObject



11
12
13
# File 'app/errors/command_tower/errors/auth/signup_ip_rate_limit_error.rb', line 11

def code
  "signup_ip_rate_limited"
end

#log_levelObject



19
20
21
# File 'app/errors/command_tower/errors/auth/signup_ip_rate_limit_error.rb', line 19

def log_level
  :warn
end

#messageObject



15
16
17
# File 'app/errors/command_tower/errors/auth/signup_ip_rate_limit_error.rb', line 15

def message
  "Too many signup requests from this network"
end