From 9c8b58d782a267b491eb418082ef5d5f1d34a6c7 Mon Sep 17 00:00:00 2001 From: Valentin Deniaud Date: Mon, 23 May 2022 09:30:09 +0200 Subject: [PATCH] authenticators: use only type as identifier in case of single instance (#65533) --- src/authentic2/apps/authenticators/models.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/authentic2/apps/authenticators/models.py b/src/authentic2/apps/authenticators/models.py index 4af6e58f8..67e9d342a 100644 --- a/src/authentic2/apps/authenticators/models.py +++ b/src/authentic2/apps/authenticators/models.py @@ -74,7 +74,7 @@ class BaseAuthenticator(models.Model): return str(self._meta.verbose_name) def get_identifier(self): - return '%s_%s' % (self.type, self.pk) + return self.type if self.internal else '%s_%s' % (self.type, self.pk) def get_absolute_url(self): return reverse('a2-manager-authenticator-detail', kwargs={'pk': self.pk}) -- 2.30.2