File tree Expand file tree Collapse file tree 1 file changed +7
-3
lines changed
services/web/server/src/simcore_service_webserver/functions/_controller Expand file tree Collapse file tree 1 file changed +7
-3
lines changed Original file line number Diff line number Diff line change 4141from .._services_metadata .proxy import ServiceMetadata
4242from ._functions_rest_exceptions import handle_rest_requests_exceptions
4343from ._functions_rest_schemas import (
44+ FunctionFilters ,
4445 FunctionGetQueryParams ,
4546 FunctionPathParams ,
4647 FunctionsListQueryParams ,
@@ -158,6 +159,11 @@ async def list_functions(request: web.Request) -> web.Response:
158159 FunctionsListQueryParams , request
159160 )
160161
162+ if not query_params .filters :
163+ query_params .filters = FunctionFilters ()
164+
165+ assert query_params .filters # nosec
166+
161167 req_ctx = AuthenticatedRequestContext .model_validate (request )
162168 functions , page_meta_info = await _functions_service .list_functions (
163169 request .app ,
@@ -166,9 +172,7 @@ async def list_functions(request: web.Request) -> web.Response:
166172 pagination_limit = query_params .limit ,
167173 pagination_offset = query_params .offset ,
168174 order_by = OrderBy .model_construct (** query_params .order_by .model_dump ()),
169- search_by_function_title = (
170- query_params .filters .search_by_title if query_params .filters else None
171- ),
175+ search_by_function_title = query_params .filters .search_by_title ,
172176 search_by_multi_columns = query_params .search ,
173177 )
174178
You can’t perform that action at this time.
0 commit comments