Skip to content

Commit

Permalink
Merge pull request #25 from nodriver-ai/interaction_required_fix
Browse files Browse the repository at this point in the history
Interaction required fix
  • Loading branch information
chipscal authored Jul 8, 2024
2 parents f19ed7a + 8418ef3 commit 60d7678
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
5 changes: 4 additions & 1 deletion lib/web/B2CProviderWeb.dart
Original file line number Diff line number Diff line change
Expand Up @@ -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 =
Expand Down Expand Up @@ -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,
Expand Down
2 changes: 1 addition & 1 deletion pubspec.yaml
Original file line number Diff line number Diff line change
@@ -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:
Expand Down

0 comments on commit 60d7678

Please sign in to comment.