From 2a741a28e0db860baf8004aceda69f3b29513e92 Mon Sep 17 00:00:00 2001 From: SBiOSoftWhare Date: Tue, 13 Aug 2019 17:03:05 +0200 Subject: [PATCH] AuthenticationViewController: When register do not propose to add 3rd party ids if there is no configured Identity Server. --- .../AuthenticationViewController.m | 19 ++++++++++++++----- 1 file changed, 14 insertions(+), 5 deletions(-) diff --git a/Riot/Modules/Authentication/AuthenticationViewController.m b/Riot/Modules/Authentication/AuthenticationViewController.m index 69f1b758f..b2e6c709f 100644 --- a/Riot/Modules/Authentication/AuthenticationViewController.m +++ b/Riot/Modules/Authentication/AuthenticationViewController.m @@ -614,11 +614,20 @@ else { [self.authenticationActivityIndicator stopAnimating]; - - // Show the supported 3rd party ids which may be added to the account - authInputsview.thirdPartyIdentifiersHidden = NO; - - [self updateRegistrationScreenWithThirdPartyIdentifiersHidden:NO]; + + BOOL isIdentityServerConfigured = self.identityServerTextField.text.length > 0; + + if (isIdentityServerConfigured) + { + // Show the supported 3rd party ids which may be added to the account + authInputsview.thirdPartyIdentifiersHidden = NO; + [self updateRegistrationScreenWithThirdPartyIdentifiersHidden:NO]; + } + else + { + // Do not propose to add 3rd party ids if there is no configured Identity Server + [super onButtonPressed:sender]; + } } }]; }