From ca4905220d68b2a748ca1f0899be3e83196b7b2a Mon Sep 17 00:00:00 2001 From: mercury Date: Sat, 5 Apr 2025 00:36:08 +0400 Subject: [PATCH] np/oc the domain is preserved when transferring --- app/bot.php | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/app/bot.php b/app/bot.php index 7466633..77ec239 100644 --- a/app/bot.php +++ b/app/bot.php @@ -6855,7 +6855,13 @@ DNS-over-HTTPS with IP: public function getHashSubdomain($subdomain) { - return $this->getPacConf()["{$subdomain}_domain"] ?: substr(hash('sha256', "$subdomain{$this->key}"), 0, 8); + $p = $this->getPacConf(); + if (!empty($p["{$subdomain}_domain"])) { + return $p["{$subdomain}_domain"]; + } + $p["{$subdomain}_domain"] = substr(hash('sha256', "$subdomain{$this->key}"), 0, 8); + $this->setPacConf($p); + return $p["{$subdomain}_domain"]; } public function addWg($page)