Skip to content

Commit fdabc3a

Browse files
Style: Auto-format code with Black to pass CI/CD check
1 parent 2fc9f29 commit fdabc3a

File tree

4 files changed

+6
-16
lines changed

4 files changed

+6
-16
lines changed

app/api/v1/admin/auth.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ async def login_access_token(
2222
OAuth2 compatible token login, get an access token for future requests.
2323
"""
2424
user = await user_repo.get_by_email(session, email=form_data.username)
25-
25+
2626
# We explicitly cast to str() here to prevent Mypy from confusing
2727
# the ORM Column definition with the actual string value.
2828
if not user or not await security.verify_password(

app/api/v1/content/guides.py

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -43,9 +43,7 @@ async def create_guide(
4343
"""
4444
Create a new guide.
4545
"""
46-
guide = await service.create_guide(
47-
session, current_client=current_client, guide_in=guide_in
48-
)
46+
guide = await service.create_guide(session, current_client=current_client, guide_in=guide_in)
4947
return GuideListResponse.model_validate(guide)
5048

5149

@@ -60,9 +58,7 @@ async def read_guide(
6058
"""
6159
Get guide by ID.
6260
"""
63-
guide = await service.get_guide(
64-
session, current_client=current_client, guide_id=guide_id
65-
)
61+
guide = await service.get_guide(session, current_client=current_client, guide_id=guide_id)
6662
if not guide:
6763
raise HTTPException(
6864
status_code=status.HTTP_404_NOT_FOUND,

app/api/v1/content/topics.py

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -40,9 +40,7 @@ async def create_topic(
4040
"""
4141
Create a new topic.
4242
"""
43-
topic = await service.create_topic(
44-
session, current_client=current_client, topic_in=topic_in
45-
)
43+
topic = await service.create_topic(session, current_client=current_client, topic_in=topic_in)
4644
return TopicResponse.model_validate(topic)
4745

4846

@@ -80,9 +78,7 @@ async def read_topic(
8078
"""
8179
Get topic by ID.
8280
"""
83-
topic = await service.get_topic(
84-
session, current_client=current_client, topic_id=topic_id
85-
)
81+
topic = await service.get_topic(session, current_client=current_client, topic_id=topic_id)
8682
if not topic:
8783
raise HTTPException(
8884
status_code=status.HTTP_404_NOT_FOUND,

app/services/content.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -43,9 +43,7 @@ async def get_topic(
4343

4444
# Access control
4545
if topic.client_id is not None and topic.client_id != current_client.id:
46-
raise HTTPException(
47-
status_code=status.HTTP_404_NOT_FOUND, detail="Topic not found"
48-
)
46+
raise HTTPException(status_code=status.HTTP_404_NOT_FOUND, detail="Topic not found")
4947

5048
return topic
5149

0 commit comments

Comments
 (0)