Skip to content

Commit 74bb3c9

Browse files
committed
[MIG] fastapi_auth_api_key: Migration to 18.0
1 parent 41a4cfc commit 74bb3c9

4 files changed

Lines changed: 6 additions & 6 deletions

File tree

fastapi_auth_api_key/README.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ Contributors
101101
Other credits
102102
-------------
103103

104-
The migration of this module from 16.0 to 17.0 was financially supported
104+
The migration of this module from 17.0 to 18.0 was financially supported
105105
by Camptocamp
106106

107107
Maintainers

fastapi_auth_api_key/__manifest__.py

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

44
{
55
"name": "Fastapi Auth API Key",
6-
"version": "17.0.1.0.0",
6+
"version": "18.0.1.0.0",
77
"category": "Others",
88
"website": "https://github.com/OCA/rest-framework",
99
"author": "Camptocamp, Odoo Community Association (OCA)",

fastapi_auth_api_key/dependencies.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
import os
44
from typing import Annotated
55

6-
from odoo import SUPERUSER_ID, _
6+
from odoo import SUPERUSER_ID
77
from odoo.api import Environment
88
from odoo.exceptions import ValidationError
99

@@ -27,7 +27,7 @@ def authenticated_auth_api_key(
2727
if not key:
2828
raise HTTPException(
2929
status_code=status.HTTP_401_UNAUTHORIZED,
30-
detail=_("Missing %(HTTP_API_KEY_HEADER)s header")
30+
detail=env._("Missing %(HTTP_API_KEY_HEADER)s header")
3131
% {"HTTP_API_KEY_HEADER": HTTP_API_KEY_HEADER},
3232
headers={"WWW-Authenticate": HTTP_API_KEY_HEADER},
3333
)
@@ -47,7 +47,7 @@ def authenticated_auth_api_key(
4747
):
4848
raise HTTPException(
4949
status_code=status.HTTP_401_UNAUTHORIZED,
50-
detail=_("Unauthorized"),
50+
detail=env._("Unauthorized"),
5151
headers={"WWW-Authenticate": HTTP_API_KEY_HEADER},
5252
)
5353
return auth_api_key
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
The migration of this module from 16.0 to 17.0 was financially supported
1+
The migration of this module from 17.0 to 18.0 was financially supported
22
by Camptocamp

0 commit comments

Comments
 (0)