app: delete messages when none of the provided units exist

Fix #321.