BugFix for NPE on null ZappedNote

This commit is contained in:
Vitor Pamplona
2023-05-05 13:26:55 -04:00
parent 5b6b6f19e5
commit 49a8778975
@@ -191,8 +191,8 @@ class Account(
) )
} }
fun calculateIfNoteWasZappedByAccount(zappedNote: Note): Boolean { fun calculateIfNoteWasZappedByAccount(zappedNote: Note?): Boolean {
return zappedNote.isZappedBy(userProfile(), this) == true return zappedNote?.isZappedBy(userProfile(), this) == true
} }
fun calculateZappedAmount(zappedNote: Note?): BigDecimal { fun calculateZappedAmount(zappedNote: Note?): BigDecimal {