Added poll messages #2557

This commit is contained in:
Priit Tark 2015-08-10 14:00:39 +03:00
parent c637d3f856
commit 86900fb839
5 changed files with 23 additions and 0 deletions

View file

@ -348,6 +348,14 @@ class Domain < ActiveRecord::Base
true
end
def poll_message!(message_key)
registrar.messages.create!(
body: I18n.t(message_key),
attached_obj_id: id,
attached_obj_type: self.class.to_s
)
end
def preclean_pendings
self.registrant_verification_token = nil
self.registrant_verification_asked_at = nil