Merge pull request #1979 from Hafizzle/Fiz/fix-duplicate-inapp-notifications

Fix duplicate in-app notification views
This commit is contained in:
Phillip Thelen 2023-05-18 13:44:22 +02:00 committed by GitHub
commit b0814cde07
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -141,7 +141,11 @@ class NotificationsActivity : BaseActivity(), androidx.swiperefreshlayout.widget
}
if (item != null) {
binding.notificationItems.addView(item)
item.tag = it.id
if (binding.notificationItems.findViewWithTag<View>(it.id) == null) {
binding.notificationItems.addView(item)
}
}
}
}