PublicAsset empty check before calling destroy on discard identity

This commit is contained in:
DatDang
2024-08-22 11:58:17 +07:00
committed by Dat H. Pham
parent c482f6188e
commit 339eeef1c2
2 changed files with 44 additions and 4 deletions
@@ -187,7 +187,7 @@ class PublicAssetController extends BaseController {
}
void discardChanges() {
if (session == null || accountId == null) return;
if (session == null || accountId == null || newlyPickedPublicAssetIds.isEmpty) return;
consumeState(_deletePublicAssetsInteractor.execute(
session!,
accountId!,