Skip to content

Commit 8aeef17

Browse files
committed
cleanup
1 parent b1e55c9 commit 8aeef17

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

src/django_idom/hooks.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,6 +112,7 @@ def use_query(
112112
113113
Args:
114114
query: A callable that returns a Django `Model` or `QuerySet`.
115+
options: A `QueryOptions` object that can modify how the query is excuted.
115116
*args: Positional arguments to pass into `query`.
116117
117118
Keyword Args:
@@ -158,7 +159,7 @@ def execute_query() -> None:
158159

159160
# Use a custom postprocessor, if provided
160161
if query_options.postprocessor:
161-
query_options.postprocessor(query_options)
162+
query_options.postprocessor(data, query_options)
162163

163164
# Use the default postprocessor
164165
else:

src/django_idom/types.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,6 @@ class QueryOptions:
6262
)
6363
"""Configuration values usable by the `postprocessor`."""
6464

65-
postprocessor: Callable[[QueryOptions], None] | None = None
65+
postprocessor: Callable[[_Data, QueryOptions], None] | None = None
6666
"""A post processing callable that can read/modify the `QueryOptions` object. If unset, the default fetch
6767
handler is used to prevent lazy loading of Django fields."""

0 commit comments

Comments
 (0)