diff --git a/tracker/index.js b/tracker/index.js index 60957d76..a30a0220 100644 --- a/tracker/index.js +++ b/tracker/index.js @@ -17,7 +17,7 @@ import { post, hook, doNotTrack } from '../lib/web'; if (!script || (__DNT__ && doNotTrack())) return; const website = script.getAttribute('data-website-id'); - const hostUrl = new URL(script.src).origin; + const hostUrl = new URL(script.src).href.split('/').slice(0, -1).join('/'); const screen = `${width}x${height}`; const listeners = [];