Skip to content

Commit 1360bfe

Browse files
authored
chore: fix false positives in CodeQL for TS (#17139)
Fixes some false positives flagged by CodeQL
1 parent eded0ed commit 1360bfe

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

site/src/utils/apps.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ export const createAppLinkHref = (
2929
}
3030

3131
if (appsHost && app.subdomain && app.subdomain_name) {
32-
const baseUrl = `${protocol}//${appsHost.replace("*", app.subdomain_name)}`;
32+
const baseUrl = `${protocol}//${appsHost.replace(/\*/g, app.subdomain_name)}`;
3333
const url = new URL(baseUrl);
3434
url.pathname = "/";
3535

site/src/utils/portForward.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ export const portForwardURL = (
1515

1616
const subdomain = `${port}${suffix}--${agentName}--${workspaceName}--${username}`;
1717

18-
const baseUrl = `${location.protocol}//${host.replace("*", subdomain)}`;
18+
const baseUrl = `${location.protocol}//${host.replace(/\*/g, subdomain)}`;
1919
const url = new URL(baseUrl);
2020
if (pathname) {
2121
url.pathname = pathname;

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy