use global ids for message reply to addresses fixes #7723
test plan: * send someone a message on another shard * reply to that message * it should be added to the conversation Change-Id: Id4439bd63f8805660d302a04e54bd47f304e29b2 Reviewed-on: https://gerrit.instructure.com/9545 Tested-by: Hudson <hudson@instructure.com> Reviewed-by: Brian Palmer <brianp@instructure.com>
This commit is contained in:
parent
2371823f47
commit
0a4bae9b84
|
@ -309,7 +309,7 @@ class Message < ActiveRecord::Base
|
|||
end
|
||||
|
||||
def reply_to_secure_id
|
||||
Canvas::Security.hmac_sha1(self.id.to_s)
|
||||
Canvas::Security.hmac_sha1(self.global_id.to_s)
|
||||
end
|
||||
|
||||
def reply_to_address
|
||||
|
@ -318,7 +318,7 @@ class Message < ActiveRecord::Base
|
|||
res = self.from if self.context_type == 'ErrorReport'
|
||||
unless res
|
||||
addr, domain = HostUrl.outgoing_email_address.split(/@/)
|
||||
res = "#{addr}+#{self.reply_to_secure_id}-#{self.id}@#{domain}"
|
||||
res = "#{addr}+#{self.reply_to_secure_id}-#{self.global_id}@#{domain}"
|
||||
end
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in New Issue