Skip to content

Commit a983ccc

Browse files
legalsylvainGeorge Daramouskas
authored andcommitted
[FIX] auth_admin_passkey : AccessError sending mail (OCA#1298)
* [FIX] AccessError sending mail
1 parent ff84e2a commit a983ccc

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

auth_admin_passkey/__manifest__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55

66
{
77
'name': 'Authentification - Admin Passkey',
8-
'version': '10.0.1.0.0',
8+
'version': '10.0.1.0.1',
99
'category': 'base',
1010
'author': "GRAP,Odoo Community Association (OCA)",
1111
'website': 'http://www.grap.coop',

auth_admin_passkey/models/res_users.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ def _send_email_passkey(self, user_id):
1919
mail_obj = self.env['mail.mail'].sudo()
2020
icp_obj = self.env['ir.config_parameter']
2121

22-
admin_user = self.browse(SUPERUSER_ID)
22+
admin_user = self.sudo().browse(SUPERUSER_ID)
2323
login_user = self.browse(user_id)
2424

2525
send_to_admin = safe_eval(

0 commit comments

Comments
 (0)