Normalize server input to lowercase in RpcClient constructor

This commit is contained in:
netkas 2025-03-27 12:52:39 -04:00
parent dff25f31ba
commit fb31c3cc6a
Signed by: netkas
GPG key ID: 4D8629441B76E4CC

View file

@ -59,6 +59,10 @@
public function __construct(string|PeerAddress $identifiedAs, ?string $server=null, ?ExportedSession $exportedSession=null) public function __construct(string|PeerAddress $identifiedAs, ?string $server=null, ?ExportedSession $exportedSession=null)
{ {
$this->logger = new \LogLib2\Logger('net.nosial.socialbox'); $this->logger = new \LogLib2\Logger('net.nosial.socialbox');
if($server !== null)
{
$server = strtolower($server);
}
// If an exported session is provided, no need to re-connect. // If an exported session is provided, no need to re-connect.
// Just use the session details provided. // Just use the session details provided.