This commit is contained in:
2021-05-08 01:06:59 +08:00
parent 88b7b52641
commit 07be685de9

View File

@@ -28,6 +28,9 @@ ProxyConfig parseProxyConfig(String config) {
final jsonConfig = json.decode(config); final jsonConfig = json.decode(config);
final managementConfig = jsonConfig['managementConfig']; final managementConfig = jsonConfig['managementConfig'];
if (managementConfig != null) {
final managementListen = managementConfig['listen'];
}
print(managementConfig); print(managementConfig);
// print(jsonConfig); // print(jsonConfig);
@@ -42,7 +45,7 @@ HostAndPort parseHostAndPort(String hnp) {
var host = hnp.substring(0, indexOfC); var host = hnp.substring(0, indexOfC);
final port = int.parse(hnp.substring(indexOfC + 1)); final port = int.parse(hnp.substring(indexOfC + 1));
if (host.isEmpty) { if (host.isEmpty) {
host = "0.0.0.0"; host = '0.0.0.0';
} }
return HostAndPort(host: host, port: port); return HostAndPort(host: host, port: port);
} }