|
|
|
@ -6,6 +6,7 @@ import io.legado.app.base.BaseViewModel |
|
|
|
|
import io.legado.app.data.appDb |
|
|
|
|
import io.legado.app.data.entities.RssSource |
|
|
|
|
import io.legado.app.help.RuleComplete |
|
|
|
|
import io.legado.app.help.http.CookieStore |
|
|
|
|
import io.legado.app.utils.getClipText |
|
|
|
|
import io.legado.app.utils.msg |
|
|
|
|
import io.legado.app.utils.printOnDebug |
|
|
|
@ -77,6 +78,12 @@ class RssSourceEditViewModel(application: Application) : BaseViewModel(applicati |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
fun clearCookie(url: String) { |
|
|
|
|
execute { |
|
|
|
|
CookieStore.removeCookie(url) |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
fun ruleComplete(rule: String?, preRule: String? = null, type: Int = 1): String? { |
|
|
|
|
if (autoComplete) { |
|
|
|
|
return RuleComplete.autoComplete(rule, preRule, type) |
|
|
|
|