PM-7855 Fix null check to _appOptions to avoid NRE detected on AppCenter (#3209)

This commit is contained in:
Federico Maccaroni 2024-05-02 20:07:52 -03:00 committed by GitHub
parent e4841bb322
commit 0b28b954fe
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
6 changed files with 24 additions and 6 deletions

View File

@ -233,7 +233,10 @@ namespace Bit.App.Pages
}
var previousPage = await AppHelpers.ClearPreviousPage();
_appOptions.HasJustLoggedInOrUnlocked = true;
if (_appOptions != null)
{
_appOptions.HasJustLoggedInOrUnlocked = true;
}
App.MainPage = new TabsPage(_appOptions, previousPage);
}
}

View File

@ -36,7 +36,10 @@ namespace Bit.App.Pages
return;
}
_appOptions.HasJustLoggedInOrUnlocked = true;
if (_appOptions != null)
{
_appOptions.HasJustLoggedInOrUnlocked = true;
}
var previousPage = await AppHelpers.ClearPreviousPage();
App.MainPage = new TabsPage(_appOptions, previousPage);
}

View File

@ -196,7 +196,10 @@ namespace Bit.App.Pages
return;
}
_appOptions.HasJustLoggedInOrUnlocked = true;
if (_appOptions != null)
{
_appOptions.HasJustLoggedInOrUnlocked = true;
}
var previousPage = await AppHelpers.ClearPreviousPage();
App.MainPage = new TabsPage(_appOptions, previousPage);
}

View File

@ -56,7 +56,10 @@ namespace Bit.App.Pages
return;
}
_appOptions.HasJustLoggedInOrUnlocked = true;
if (_appOptions != null)
{
_appOptions.HasJustLoggedInOrUnlocked = true;
}
var previousPage = await AppHelpers.ClearPreviousPage();
App.MainPage = new TabsPage(_appOptions, previousPage);
}

View File

@ -72,7 +72,10 @@ namespace Bit.App.Pages
return;
}
_appOptions.HasJustLoggedInOrUnlocked = true;
if (_appOptions != null)
{
_appOptions.HasJustLoggedInOrUnlocked = true;
}
var previousPage = await AppHelpers.ClearPreviousPage();
App.MainPage = new TabsPage(_appOptions, previousPage);
}

View File

@ -207,7 +207,10 @@ namespace Bit.App.Pages
return;
}
_appOptions.HasJustLoggedInOrUnlocked = true;
if (_appOptions != null)
{
_appOptions.HasJustLoggedInOrUnlocked = true;
}
var previousPage = await AppHelpers.ClearPreviousPage();
App.MainPage = new TabsPage(_appOptions, previousPage);
}