tv: add text when there are no tunnels

Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
This commit is contained in:
Jason A. Donenfeld
2020-09-22 23:54:38 +02:00
parent 10bb413187
commit 03189e7b20
3 changed files with 18 additions and 1 deletions
@@ -84,6 +84,8 @@ class TvMainActivity : AppCompatActivity() {
if (isDeleting.get()) {
try {
item.deleteAsync()
if (this@TvMainActivity.binding.tunnels?.isEmpty() != false)
isDeleting.set(false)
} catch (e: Throwable) {
val error = ErrorMessages[e]
val message = getString(R.string.config_delete_error, error)