refactor(android): remove unreachable backend dispatch fallbacks

This commit is contained in:
zarzet committed 2026-10-18 00:46:09 +07:00
1 parent 4b732439e8
commit fdcd291c78
1 file changed
-24
@@ -1164,15 +1164,6 @@ class MainActivity: FlutterFragmentActivity() {
}
result.success(response)
}
"acquireDownloadDirectory" -> {
val path = call.argument<String>("path") ?: ""
withContext(Dispatchers.IO) {
coreBackend.openDownloadDirectory(path).close()
}
// Go grants have process lifetime; Rust owns scoped tokens in its dispatcher.
result.success("")
}
"releaseDownloadDirectory" -> result.success(null)
"getBackendImplementations" -> {
result.success(
mapOf(
@@ -1183,21 +1174,6 @@ class MainActivity: FlutterFragmentActivity() {
)
)
}
"buildFilename" -> {
val template = call.argument<String>("template") ?: ""
val metadata = call.argument<String>("metadata") ?: "{}"
val response = withContext(Dispatchers.IO) {
coreBackend.buildFilename(template, metadata)
}
result.success(response)
}
"sanitizeFilename" -> {
val filename = call.argument<String>("filename") ?: ""
val response = withContext(Dispatchers.IO) {
coreBackend.sanitizeFilename(filename)
}
result.success(response)
}
"pickSafTree" -> {
if (pendingSafTreeResult != null) {
result.error("saf_pending", "SAF picker already active", null)