From c488901dc5715b6223a468a8ec9cea8b5bfb38b0 Mon Sep 17 00:00:00 2001 From: Raphael Michel Date: Fri, 12 Sep 2025 15:45:37 +0200 Subject: [PATCH] Adjust spec of filter_subevents signal (#5462) * Adjus tspec of filter_subevents signal * Fix typos --------- Co-authored-by: Richard Schreiber --- src/pretix/presale/signals.py | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/src/pretix/presale/signals.py b/src/pretix/presale/signals.py index 75d48506a..267be37dd 100644 --- a/src/pretix/presale/signals.py +++ b/src/pretix/presale/signals.py @@ -424,10 +424,12 @@ This signal allows you to filter which subevents are publicly available. Receive list of subevents that are about to be shown to the user and are expected to return a list of the same format, with all subevents removed that should not be available for sale. -``sales_channels`` is a ``SalesChannel`` instance. +``sales_channels`` is a ``str`` with the sales channel identifier. -This is not an event-plugin signal as this will also be called on the organizer level when showing +This is not an event-plugin signal as this will also be called on other levels when showing a list of subevents across events. Expect that the subevents in the input are mixed from different -events. However, receivers will only receive subevents of events that the plugin is active for and -can only filter out these. +events **or even different organizers**. However, receivers will only receive subevents of events +that the plugin is active for and can only filter out these. It is recommended that receivers +return a subset of the same subevent instances that are passed in, not new instances, to ensure +`prefetch_related` calls on the caller side are not pointless. """