From d67b295d364985ffdc1d9b55e66f11002e77dd8d Mon Sep 17 00:00:00 2001 From: wlorenzetti Date: Fri, 13 Oct 2023 12:05:08 +0200 Subject: [PATCH] Fix anonymous user subset filter. --- g3w-admin/qdjango/models/constraints.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/g3w-admin/qdjango/models/constraints.py b/g3w-admin/qdjango/models/constraints.py index fc0cafa66..615dbb0e0 100644 --- a/g3w-admin/qdjango/models/constraints.py +++ b/g3w-admin/qdjango/models/constraints.py @@ -240,7 +240,7 @@ def get_constraints_for_anonymoususer(cls, layer_id, context='v'): if not constraints: return [] - return cls.objects.filter(anonymoususer=True) + return cls.objects.filter(anonymoususer=True, constraint__in=constraints) @classmethod def get_rule_definition_for_user(cls, user, layer_id, context='v'):