Skip to content

Commit

Permalink
refactor: Bug fix for test 6
Browse files Browse the repository at this point in the history
  • Loading branch information
bibash28 committed Aug 15, 2023
1 parent 45914ad commit 9f41af8
Showing 1 changed file with 5 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -530,7 +530,8 @@ class QRCodeScanCubit extends Cubit<QRCodeScanState> {
}

Future<bool> isVCPresentable(
PresentationDefinition? presentationDefinition) async {
PresentationDefinition? presentationDefinition,
) async {
if (presentationDefinition != null &&
presentationDefinition.inputDescriptors.isNotEmpty) {
for (final descriptor in presentationDefinition.inputDescriptors) {
Expand All @@ -548,8 +549,9 @@ class QRCodeScanCubit extends Cubit<QRCodeScanState> {
final credentialName = credentialField['filter']['pattern'] as String;

final isPresentable = await isCredentialPresentable(credentialName);

return isPresentable;
if (!isPresentable) {
return false;
}
}
}
return true;
Expand Down

0 comments on commit 9f41af8

Please sign in to comment.