Skip to content
This repository was archived by the owner on May 28, 2025. It is now read-only.

fix/NPE occur when require the token before initial job finish.#8

Open
lvsecoto wants to merge 1 commit intoBritehouseMobile:masterfrom
lvsecoto:fix/NPE_Initial_Job
Open

fix/NPE occur when require the token before initial job finish.#8
lvsecoto wants to merge 1 commit intoBritehouseMobile:masterfrom
lvsecoto:fix/NPE_Initial_Job

Conversation

@lvsecoto
Copy link
Copy Markdown

@lvsecoto lvsecoto commented Sep 3, 2020

I found a NPE problem when I acquire token meanwhile mSingleAccountApp is null, because init hasn't been finished.

We should wait unit init is finished, then do other job.

In this pull request, I fix this problem.

And now you should:

final fma = FlutterMicrosoftAuthentication();
await fma.ensureInitialized();

And now you should:

```dart
final fma = FlutterMicrosoftAuthentication();
await fma.ensureInitialized();
```
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant