mirror of
https://github.com/internetee/registry.git
synced 2025-08-05 09:21:43 +02:00
Move apply_pending_update! method from model to interactor
This commit is contained in:
parent
4b7cffbb57
commit
8ef748fc7d
6 changed files with 56 additions and 30 deletions
|
@ -327,6 +327,7 @@ class Domain < ApplicationRecord
|
|||
end
|
||||
|
||||
def notify_registrar(message_key)
|
||||
# TODO: To be deleted with DomainDeleteConfirm refactoring
|
||||
registrar.notifications.create!(
|
||||
text: "#{I18n.t(message_key)}: #{name}",
|
||||
attached_obj_id: id,
|
||||
|
@ -335,11 +336,13 @@ class Domain < ApplicationRecord
|
|||
end
|
||||
|
||||
def preclean_pendings
|
||||
# TODO: To be deleted with refactoring
|
||||
self.registrant_verification_token = nil
|
||||
self.registrant_verification_asked_at = nil
|
||||
end
|
||||
|
||||
def clean_pendings!
|
||||
# TODO: To be deleted with refactoring
|
||||
preclean_pendings
|
||||
self.pending_json = {}
|
||||
statuses.delete(DomainStatus::PENDING_DELETE_CONFIRMATION)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue