diff --git a/.rubocop.yml b/.rubocop.yml index eb580f9ce18c4c27699bcae5d8a61846d64363a6..d9efb21dfb8e36b6ea04f75f28d30fdad3b0246c 100644 --- a/.rubocop.yml +++ b/.rubocop.yml @@ -81,3 +81,6 @@ Style/FormatString: Style/FormatStringToken: EnforcedStyle: unannotated + +Naming/AccessorMethodName: + Enabled: false diff --git a/lib/backend_sgx.rb b/lib/backend_sgx.rb index 30b45137dd97b602137d82382279983d30805daa..8001e96674cfdb78cf786f74fa0ea5a3643ad49c 100644 --- a/lib/backend_sgx.rb +++ b/lib/backend_sgx.rb @@ -33,7 +33,7 @@ class BackendSgx end end - def fwd_timeout=(timeout) + def set_fwd_timeout(timeout) REDIS.set("catapult_fwd_timeout-#{from_jid}", timeout) end diff --git a/lib/customer.rb b/lib/customer.rb index d5e7d1c578ed29982906c6c9a7e0b7d6637c372e..160013041ccc17f883b8d5e38836de75ce53a033 100644 --- a/lib/customer.rb +++ b/lib/customer.rb @@ -20,7 +20,7 @@ class Customer attr_reader :customer_id, :balance, :jid def_delegators :@plan, :active?, :activate_plan_starting_now, :bill_plan, :currency, :merchant_account, :plan_name, :auto_top_up_amount - def_delegators :@sgx, :register!, :registered?, :fwd_timeout= + def_delegators :@sgx, :register!, :registered?, :set_fwd_timeout def_delegators :@usage, :usage_report, :message_usage, :incr_message_usage def initialize( diff --git a/lib/registration.rb b/lib/registration.rb index a34bdec776f1dd4bf1db1d3705ee50ee6c0dee48..a5984dbe9d3ab2c15e0efe48d3fd5937b29c59d9 100644 --- a/lib/registration.rb +++ b/lib/registration.rb @@ -455,7 +455,7 @@ class Registration EMPromise.all([ REDIS.del("pending_tel_for-#{@customer.jid}"), REDIS.set("catapult_fwd-#{@tel}", cheogram_sip_addr), - @customer.fwd_timeout = 25 # ~5 seconds / ring, 5 rings + @customer.set_fwd_timeout(25) # ~5 seconds / ring, 5 rings ]) }.then do Command.finish("Your JMP account has been activated as #{@tel}")