Update V2rayN.php

This commit is contained in:
ishkong 2024-01-13 17:25:11 +08:00 committed by GitHub
parent 0000c071e7
commit 0b5baa70f0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -205,7 +205,8 @@ class V2rayN
public static function buildHysteria($password, $server)
{
$name = rawurlencode($server['name']);
if ($server['server_name']) $params = ['sni' => $server['server_name']];
$params = [];
if ($server['server_name']) $params['sni'] = $server['server_name'];
$params['insecure'] = $server['insecure'] ? 1 : 0;
$query = http_build_query($params);
if ($server['version'] == 2) {