From 5520e4e02e59b5df66a6803cf42aaafe479f1a78 Mon Sep 17 00:00:00 2001 From: Corewala Date: Fri, 7 Jan 2022 18:52:19 -0500 Subject: [PATCH] Fixed error in onResume() and removed unnecessary fix in OmniTerm.kt --- app/src/main/java/corewala/buran/OmniTerm.kt | 6 +----- app/src/main/java/corewala/buran/ui/GemActivity.kt | 5 ----- 2 files changed, 1 insertion(+), 10 deletions(-) diff --git a/app/src/main/java/corewala/buran/OmniTerm.kt b/app/src/main/java/corewala/buran/OmniTerm.kt index f205ec6..3da8cb8 100644 --- a/app/src/main/java/corewala/buran/OmniTerm.kt +++ b/app/src/main/java/corewala/buran/OmniTerm.kt @@ -1,7 +1,6 @@ package corewala.buran import android.net.Uri -import corewala.buran.Buran.Companion.DEFAULT_HOME_CAPSULE import java.util.* const val GEM_SCHEME = "gemini://" @@ -82,10 +81,7 @@ class OmniTerm(private val listener: Listener) { } fun getCurrent(): String { - if (history.isNotEmpty()){ - return history.last().toString() - } - return DEFAULT_HOME_CAPSULE + return history.last().toString() } fun canGoBack(): Boolean { diff --git a/app/src/main/java/corewala/buran/ui/GemActivity.kt b/app/src/main/java/corewala/buran/ui/GemActivity.kt index 12f46f7..1d5326d 100644 --- a/app/src/main/java/corewala/buran/ui/GemActivity.kt +++ b/app/src/main/java/corewala/buran/ui/GemActivity.kt @@ -265,11 +265,6 @@ class GemActivity : AppCompatActivity() { else -> hideClientCertShield() } - gemtext_recycler.adapter = null - adapter = AbstractGemtextAdapter.getAdapter(onLink) - gemtext_recycler.adapter = adapter - refresh() - val hideCodeBlocks = prefs.getBoolean( "collapse_code_blocks", false