Remove altervista when done

This commit is contained in:
Daniil Gentili 2020-10-13 21:56:25 +02:00
parent 37d3f94af2
commit 26bb35e921
Signed by: danog
GPG Key ID: 8C1BE3B34B230CA7
3 changed files with 4 additions and 3 deletions

View File

@ -96,10 +96,10 @@ class PhpDocBuilder
}
if (!$this->namespace) {
$namespaces = array_keys($json['autoload']['psr-4']);
$namespaces = \array_keys($json['autoload']['psr-4']);
$this->namespace = $namespaces[0];
foreach ($namespaces as $namespace) {
if (strlen($namespace) && strlen($namespace) < strlen($this->namespace)) {
if (\strlen($namespace) && \strlen($namespace) < \strlen($this->namespace)) {
$this->namespace = $namespace;
}
}

View File

@ -225,6 +225,8 @@ class Connection extends SettingsAbstract
if (Magic::$altervista) {
$this->addProxy(HttpProxy::class, ['address' => 'localhost', 'port' => 80]);
} else {
$this->removeProxy(HttpProxy::class, , ['address' => 'localhost', 'port' => 80]);
}
}
/**

View File

@ -1,6 +1,5 @@
<?php
use Amp\Sync\Internal\MutexStorage;
use danog\MadelineProto\AbstractAPIFactory;
use danog\MadelineProto\AnnotationsBuilder;
use danog\MadelineProto\APIFactory;