refactor: streamline code formatting in API and tests
Some checks failed
CI / lint-and-test (push) Failing after 1m17s
Some checks failed
CI / lint-and-test (push) Failing after 1m17s
- Consolidated function call formatting in `admin_reassign_duty` for improved readability. - Enhanced test cases by standardizing header formatting in API requests, ensuring consistency across tests. - Improved overall code clarity and maintainability by adhering to established coding style guidelines.
This commit is contained in:
@@ -374,9 +374,7 @@ def admin_reassign_duty(
|
||||
status_code=400,
|
||||
detail=t(lang, "admin.user_not_found"),
|
||||
)
|
||||
updated = update_duty_user(
|
||||
session, duty_id, body.user_id, commit=True
|
||||
)
|
||||
updated = update_duty_user(session, duty_id, body.user_id, commit=True)
|
||||
if updated is None:
|
||||
raise HTTPException(
|
||||
status_code=404,
|
||||
|
||||
Reference in New Issue
Block a user