fix warp off after update

This commit is contained in:
mercury
2024-10-26 22:18:36 +04:00
parent 9ab05de320
commit dd8897575f
2 changed files with 3 additions and 2 deletions
+2 -2
View File
@@ -4689,10 +4689,10 @@ DNS-over-HTTPS with IP:
return 'off';
}
public function offWarp()
public function offWarp($inversion = true)
{
$p = $this->getPacConf();
if (empty($p['warpoff'])) {
if ($inversion && empty($p['warpoff'])) {
$this->ssh('warp-cli --accept-tos registration delete', 'wp');
$this->ssh('pkill warp-svc', 'wp');
$p['warpoff'] = 1;