Browse Source

🌈 cleanup code

pull/349/head
Denis Mudarisov 3 years ago
parent
commit
7794392b3e
No known key found for this signature in database GPG Key ID: B9AD74DAFB7B53DA
  1. 11
      mail_private/models.py

11
mail_private/models.py

@ -16,8 +16,6 @@ class MailThread(models.AbstractModel):
_inherit = "mail.thread" _inherit = "mail.thread"
def _notify_thread(self, message, msg_vals=False, **kwargs): def _notify_thread(self, message, msg_vals=False, **kwargs):
# import wdb;wdb.set_trace()
self_sudo = self.sudo()
msg_vals = msg_vals if msg_vals else {} msg_vals = msg_vals if msg_vals else {}
return super(MailThread, self)._notify_thread(message, msg_vals) return super(MailThread, self)._notify_thread(message, msg_vals)
@ -49,7 +47,6 @@ class MailMessage(models.Model):
internal_ids = self.get_internal_users_ids() internal_ids = self.get_internal_users_ids()
recipient_ids = [r.partner_id for r in follower_ids if r.partner_id] recipient_ids = [r.partner_id for r in follower_ids if r.partner_id]
# channel_ids = [c.channel_id for c in follower_ids if c.channel_id]
for recipient in recipient_ids: for recipient in recipient_ids:
result.append( result.append(
@ -63,14 +60,6 @@ class MailMessage(models.Model):
} }
) )
# for channel in channel_ids:
# result.append({
# 'checked': True,
# 'channel_id': channel.id,
# 'full_name': channel,
# 'name': '# '+channel.name,
# 'reason': 'Channel',
# })
return result return result
def get_internal_users_ids(self): def get_internal_users_ids(self):

Loading…
Cancel
Save