fixup! Rewrite search suggestion with kotlin flow, remove suggestion limit

This commit is contained in:
tarsin committed 2022-12-18 11:31:49 +08:00
1 parent 34be285510
commit bd2d54f774
1 file changed
+1 -1
@@ -72,7 +72,7 @@ class EhTagDatabase(private val name: String, source: BufferedSource) {
}
fun getTranslation(prefix: String?, tag: String?): String? {
return tags!!.optJSONObject(prefix)?.optString(tag)
return tags!!.optJSONObject(prefix)?.optString(tag)?.trim()?.takeIf { it.isNotEmpty() }
}
/* Construct a cold flow for tag database suggestions */