Fix protect() when there is no service

This commit is contained in:
yuhan6665
2020-09-20 18:59:26 -04:00
parent 723727feb9
commit 4abf20fa32
@@ -88,7 +88,7 @@ object V2RayServiceManager {
}
override fun protect(l: Long): Long {
val serviceControl = serviceControl?.get() ?: return 1
val serviceControl = serviceControl?.get() ?: return 0
return if (serviceControl.vpnProtect(l.toInt())) 0 else 1
}