Skip to content
This repository was archived by the owner on Jun 9, 2024. It is now read-only.

Commit 48d4fb2

Browse files
committed
Fix pastaporto camel case
1 parent 9a0ff1b commit 48d4fb2

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

pythonit_toolkit/pastaporto/entities.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ class PastaportoUserInfo:
3535

3636
@classmethod
3737
def from_data(cls, data: dict[str, Any]):
38-
return cls(id=int(data["id"]), email=data["email"], is_staff=data["isStaff"])
38+
return cls(id=int(data["id"]), email=data["email"], is_staff=data["is_staff"])
3939

4040

4141
@dataclass

pythonit_toolkit/pastaporto/test.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ def fake_pastaporto_token_for_user(
1414
now = datetime.now(timezone.utc)
1515
return jwt.encode(
1616
{
17-
"userInfo": {"id": user["id"], "email": user["email"], "isStaff": staff},
17+
"user_info": {"id": user["id"], "email": user["email"], "is_staff": staff},
1818
"credentials": credentials,
1919
"exp": now + timedelta(minutes=1),
2020
"iat": now,

0 commit comments

Comments
 (0)