fix import mtproto

This commit is contained in:
mercury
2023-06-05 01:53:43 +04:00
parent 4ddaa86daf
commit 354097f8b5
+1 -1
View File
@@ -309,13 +309,13 @@ class Bot
public function secretSet($secret)
{
file_put_contents('/config/mtprotosecret', $secret ?: '');
$this->restartTG($secret);
$this->mtproto();
}
public function restartTG($secret)
{
file_put_contents('/config/mtprotosecret', $secret ?: '');
$this->ssh('pkill mtproto-proxy', 'tg');
if (preg_match('~^\w{32}$~', $secret)) {
$p = getenv('TGPORT');