mirror of
https://github.com/bitwarden/android.git
synced 2024-12-24 01:48:25 +03:00
App: Pages: Add a null check in OnSelectTemplate() (#243)
To avoid accessing a null poiter add a null check in OnSelectTemplate(). Signed-off-by: Alistair Francis <alistair@alistair23.me>
This commit is contained in:
parent
ca03a5ecf4
commit
71dd4e512e
1 changed files with 4 additions and 0 deletions
|
@ -350,6 +350,10 @@ namespace Bit.App.Pages
|
|||
|
||||
protected override DataTemplate OnSelectTemplate(object item, BindableObject container)
|
||||
{
|
||||
if(item == null)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
return ((GroupingOrCipher)item).Cipher == null ? GroupingTemplate : CipherTemplate;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue