Skip to content

Commit

Permalink
Merge pull request #1690 from PDIS/fix-url-js
Browse files Browse the repository at this point in the history
Fix #1686
  • Loading branch information
ballPointPenguin committed Jul 10, 2023
2 parents c9ff4e2 + 3291e0a commit 5d16072
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions client-report/src/util/url.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
// it should send requests to that domain.
//
// Otherwise, use the SERVICE_URL environment variable, if set, or default to
// the current document.origin (e.g. "https://mypolis.xyz/").
// the current self.origin (e.g. "https://mypolis.xyz/").

// NOTE: SERVICE_URL is currently not present in the production build via gulp.
// It is only present in the dev build via webpack-dev-server.
Expand All @@ -35,7 +35,7 @@ const getDomainPrefix = () => {

if (serviceUrl) return `${serviceUrl}/`;

return `${document.origin}/`;
return `${self.origin}/`;
};

const urlPrefix = getDomainPrefix();
Expand Down

0 comments on commit 5d16072

Please sign in to comment.