Browse Source

[FIX] auth_admin_passkey : AccessError sending mail (#1298)

* [FIX] AccessError sending mail
pull/1305/head
Sylvain LE GAL 7 years ago
committed by GitHub
parent
commit
656f38ea02
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      auth_admin_passkey/__manifest__.py
  2. 2
      auth_admin_passkey/models/res_users.py

2
auth_admin_passkey/__manifest__.py

@ -5,7 +5,7 @@
{ {
'name': 'Authentification - Admin Passkey', 'name': 'Authentification - Admin Passkey',
'version': '10.0.1.0.0',
'version': '10.0.1.0.1',
'category': 'base', 'category': 'base',
'author': "GRAP,Odoo Community Association (OCA)", 'author': "GRAP,Odoo Community Association (OCA)",
'website': 'http://www.grap.coop', 'website': 'http://www.grap.coop',

2
auth_admin_passkey/models/res_users.py

@ -19,7 +19,7 @@ class ResUsers(models.Model):
mail_obj = self.env['mail.mail'].sudo() mail_obj = self.env['mail.mail'].sudo()
icp_obj = self.env['ir.config_parameter'] icp_obj = self.env['ir.config_parameter']
admin_user = self.browse(SUPERUSER_ID)
admin_user = self.sudo().browse(SUPERUSER_ID)
login_user = self.browse(user_id) login_user = self.browse(user_id)
send_to_admin = safe_eval( send_to_admin = safe_eval(

Loading…
Cancel
Save