pull/306/head
gedoor 4 years ago
parent cc98eb587c
commit 4c193dcff5
  1. 3
      app/src/main/java/io/legado/app/ui/association/ImportReplaceRuleViewModel.kt

@ -4,7 +4,6 @@ import android.app.Application
import android.net.Uri
import androidx.documentfile.provider.DocumentFile
import androidx.lifecycle.MutableLiveData
import io.legado.app.R
import io.legado.app.base.BaseViewModel
import io.legado.app.data.entities.ReplaceRule
import io.legado.app.help.http.HttpHelper
@ -58,7 +57,7 @@ class ImportReplaceRuleViewModel(app: Application) : BaseViewModel(app) {
}.onError {
errorLiveData.postValue(it.localizedMessage ?: "ERROR")
}.onSuccess {
errorLiveData.postValue(context.getString(R.string.success))
successLiveData.postValue(allRules)
}
}
}
Loading…
Cancel
Save