This commit is contained in:
Daniel 2024-08-12 07:47:08 -04:00
parent 9d58f4fa7f
commit d6d590684d

View file

@ -9,7 +9,7 @@ class LiveFeeder {
String socketUrl = 'ws://xenon:3050/ws';
Uri baseUri = Uri.base;
if (baseUri.scheme == 'http' || baseUri.scheme == 'https') {
String port = (baseUri.hasPort ? ':' + baseUri.port.toString() : '');
String port = (baseUri.hasPort ? ':${baseUri.port}' : '');
socketUrl = 'ws://${baseUri.host}$port/ws';
}
_wsUri = Uri.parse(socketUrl);