From 13f9c6ea521a2db0d374f0a577facde44ef46ddb Mon Sep 17 00:00:00 2001 From: Mohamad Bastin Date: Tue, 9 Jan 2024 17:29:59 +0100 Subject: [PATCH] fix brightid connect url --- authentication/models.py | 2 ++ authentication/serializers.py | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/authentication/models.py b/authentication/models.py index 562247f6..fc4c8013 100644 --- a/authentication/models.py +++ b/authentication/models.py @@ -168,6 +168,7 @@ def __str__(self): class BaseThirdPartyConnection(models.Model): + title = "BaseThirdPartyConnection" user_profile = models.ForeignKey( UserProfile, on_delete=models.PROTECT, related_name="%(class)s" ) @@ -188,6 +189,7 @@ def get_connection(cls, user_profile): class BrightIDConnection(BaseThirdPartyConnection): + title = "BrightID" context_id = models.CharField(max_length=512, unique=True) driver = BrightIDConnectionDriver() diff --git a/authentication/serializers.py b/authentication/serializers.py index 0dfca9df..83e9398c 100644 --- a/authentication/serializers.py +++ b/authentication/serializers.py @@ -96,7 +96,7 @@ def get_third_party_connection_serializer(connection): def thirdparty_connection_serializer(connection_list): return [ - get_third_party_connection_serializer(connection).data + {connection.title: get_third_party_connection_serializer(connection).data} for connection in connection_list ]