diff --git a/lib/web/B2CProviderWeb.dart b/lib/web/B2CProviderWeb.dart index 74f4100..8755fff 100644 --- a/lib/web/B2CProviderWeb.dart +++ b/lib/web/B2CProviderWeb.dart @@ -59,6 +59,8 @@ class B2CProviderWeb { static const String _B2C_PASSWORD_CHANGE = "AADB2C90118"; static const String _B2C_USER_CANCELLED = "user_cancelled"; + static const String _B2C_INTERACTION_REQUIRED = "AADB2C90077"; + static const String _B2C_PLUGIN_LAST_ACCESS = "b2c_plugin_last_access"; static final DateFormat _format = @@ -355,7 +357,8 @@ class B2CProviderWeb { tag, B2COperationSource.POLICY_TRIGGER_SILENTLY, B2COperationState.CLIENT_ERROR)); - } else if (exception is InteractionRequiredAuthException) { + } else if (exception is InteractionRequiredAuthException || + exception.message.contains(_B2C_INTERACTION_REQUIRED)) { /* Tokens expired or no session, retry with interactive */ _emitCallback(B2COperationResult( tag, diff --git a/pubspec.yaml b/pubspec.yaml index 66fc25b..5052cd4 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -1,6 +1,6 @@ name: flutter_azure_b2c description: A flutter library to handle the Azure B2C authentication protocol -version: 0.0.9 +version: 0.0.10 homepage: "https://github.com/nodriver-ai/flutter_azure_b2c" environment: