mirror of
https://github.com/internetee/registry.git
synced 2025-05-16 09:27:19 +02:00
parent
954269e580
commit
f99b8b66b0
1 changed files with 5 additions and 1 deletions
|
@ -10,13 +10,17 @@ module Concerns::Contact::Transferable
|
||||||
new_contact.registrar = new_registrar
|
new_contact.registrar = new_registrar
|
||||||
new_contact.generate_code
|
new_contact.generate_code
|
||||||
new_contact.original = self
|
new_contact.original = self
|
||||||
|
new_contact.regenerate_auth_info
|
||||||
new_contact.remove_address unless self.class.address_processing?
|
new_contact.remove_address unless self.class.address_processing?
|
||||||
new_contact.save!
|
new_contact.save!
|
||||||
new_contact
|
new_contact
|
||||||
end
|
end
|
||||||
|
|
||||||
|
protected
|
||||||
|
|
||||||
def generate_auth_info
|
def generate_auth_info
|
||||||
return if auth_info.present?
|
|
||||||
self.auth_info = SecureRandom.hex(11)
|
self.auth_info = SecureRandom.hex(11)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
alias_method :regenerate_auth_info, :generate_auth_info
|
||||||
end
|
end
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue