update: add random port

This commit is contained in:
tokumeikoi
2022-02-17 02:44:49 +08:00
parent c8c96365ea
commit a1ada9183c
2 changed files with 15 additions and 1 deletions

View File

@ -112,4 +112,9 @@ class Helper
}
return $subscribeUrl;
}
public static function randomPort($range) {
$portRange = explode('-', $range);
return rand($portRange[0], $portRange[1]);
}
}