Commit 9ed3adb
committed
Address PR #1369 review: pre-commit fixes + filter naming + resolve_me type
- Apply pyupgrade/black/isort fixes (Optional → | None) and drop the
resulting unused 'Optional'/'Union' imports.
- Rename 'info: str' → 'name: str' on django-filters method signatures
in filters.py. The parameter receives the filter field name; the
'info' name was misleading copy-paste from GraphQL resolver
signatures (where 'info' is graphene.ResolveInfo).
- Widen UserQueryMixin.resolve_me return type from User to
User | AnonymousUser. The query has no @login_required, so
info.context.user can be AnonymousUser at runtime.1 parent 360194b commit 9ed3adb
7 files changed
Lines changed: 90 additions & 113 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
8 | | - | |
| 8 | + | |
9 | 9 | | |
10 | 10 | | |
11 | 11 | | |
| |||
61 | 61 | | |
62 | 62 | | |
63 | 63 | | |
64 | | - | |
| 64 | + | |
65 | 65 | | |
66 | 66 | | |
67 | 67 | | |
| |||
331 | 331 | | |
332 | 332 | | |
333 | 333 | | |
334 | | - | |
| 334 | + | |
335 | 335 | | |
336 | 336 | | |
337 | 337 | | |
| |||
0 commit comments