Skip to content

Commit

Permalink
Check if isIP
Browse files Browse the repository at this point in the history
  • Loading branch information
Janaka-Steph committed Oct 3, 2023
1 parent 1465128 commit 543f921
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/shared/helpers/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -191,7 +191,7 @@ export const UPSCALER_ID = "upscaler";
export const getServiceUrl = (invokeMethod: Service["invokeMethod"], pathname: string) => {
let serviceUrl = "http://localhost:54321";
if (isProxyEnabled()) {
if (invokeMethod.header) {
if (invokeMethod.header && isIP(window.location.host)) {
serviceUrl = `${window.location.protocol}//${window.location.host}/`;
} else {
serviceUrl = invokeMethod.baseUrl;
Expand Down

0 comments on commit 543f921

Please sign in to comment.