fix proxy parse, #492
This commit is contained in:
parent
1c6a86b164
commit
33e83cae6b
@ -78,7 +78,7 @@ object ProxyUtil {
|
|||||||
@JvmOverloads
|
@JvmOverloads
|
||||||
fun parseProxies(text: String, tryDecode: Boolean = true): MutableList<String> {
|
fun parseProxies(text: String, tryDecode: Boolean = true): MutableList<String> {
|
||||||
|
|
||||||
if (tryDecode) {
|
if (tryDecode && !text.contains("proxies:")) {
|
||||||
try {
|
try {
|
||||||
return parseProxies(String(Base64.decode(text, Base64.NO_PADDING)), false)
|
return parseProxies(String(Base64.decode(text, Base64.NO_PADDING)), false)
|
||||||
} catch (ignored: Exception) {
|
} catch (ignored: Exception) {
|
||||||
@ -98,7 +98,7 @@ object ProxyUtil {
|
|||||||
} catch (ignored: JSONException) {
|
} catch (ignored: JSONException) {
|
||||||
}
|
}
|
||||||
|
|
||||||
if (text.contains("proxies:\n")) {
|
if (text.contains("proxies:")) {
|
||||||
|
|
||||||
if (BuildVars.isMini) {
|
if (BuildVars.isMini) {
|
||||||
error(LocaleController.getString("MiniVersionAlert", R.string.MiniVersionAlert))
|
error(LocaleController.getString("MiniVersionAlert", R.string.MiniVersionAlert))
|
||||||
|
Loading…
Reference in New Issue
Block a user