Fix unable to connect to console using Remote Play in some cases

This commit is contained in:
redphx
2025-03-11 17:27:59 +07:00
parent 55d7796f96
commit 5dd3ebdea1
4 changed files with 26 additions and 12 deletions

View File

@@ -49,8 +49,11 @@ function updateIceCandidates(candidates: any, options: { preferIpv6Server: boole
continue;
}
const groups: { [index: string]: string | number } = pattern.exec(item.candidate)!.groups!;
lst.push(groups);
const match = pattern.exec(item.candidate);
if (match && match.groups) {
const groups: { [index: string]: string | number } = match.groups;
lst.push(groups);
}
}
if (options.preferIpv6Server) {