From c17eb00e3b81affe11d88b8ed3b1bff95ca57930 Mon Sep 17 00:00:00 2001 From: Jens Langhammer Date: Sat, 3 Apr 2021 12:08:21 +0200 Subject: [PATCH] providers/oauth2: fix component for Scope Signed-off-by: Jens Langhammer --- authentik/core/api/providers.py | 3 +++ authentik/providers/oauth2/models.py | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/authentik/core/api/providers.py b/authentik/core/api/providers.py index 363f08ef7..7108dce0b 100644 --- a/authentik/core/api/providers.py +++ b/authentik/core/api/providers.py @@ -25,6 +25,9 @@ class ProviderSerializer(ModelSerializer, MetaNameSerializer): def get_component(self, obj: Provider): # pragma: no cover """Get object component so that we know how to edit the object""" + # pyright: reportGeneralTypeIssues=false + if obj.__class__ == Provider: + return "" return obj.component class Meta: diff --git a/authentik/providers/oauth2/models.py b/authentik/providers/oauth2/models.py index f44788f7e..d8594cd11 100644 --- a/authentik/providers/oauth2/models.py +++ b/authentik/providers/oauth2/models.py @@ -112,7 +112,7 @@ class ScopeMapping(PropertyMapping): @property def component(self) -> str: - return "ak-service-connection-docker-form" + return "ak-property-mapping-scope-form" @property def serializer(self) -> Type[Serializer]: