Skip to content
Snippets Groups Projects
Commit 9f538866 authored by Alexey Lunin's avatar Alexey Lunin
Browse files

Fix the issue when window.currentlyLoadedIdentity set to null while executing...

Fix the issue when window.currentlyLoadedIdentity set to null while executing await loadIdentityInternal
parent f867fe34
Branches 448-forgetting-credentials-shows-error
No related tags found
1 merge request!31Forgetting credentials shows error in the console but works
......@@ -1277,7 +1277,7 @@ connection.promise.then(parent => {
if (!pinCode) {
if (!identityLoadedEvent) {
const result = await loadIdentityInternal(window.currentlyLoadedIdentity.authentication.publicKey, "00000000");
if (result.code !== "200") {
if (window.currentlyLoadedIdentity && result.code !== "200") {
const event = createEvent("CanNotLoadPincodeForLoadedIdentity", "IdentityNotLoaded", [window.currentlyLoadedIdentity.authentication.publicKey]);
parent.onEvent(event);
identityLoadedEvent = true;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment