[CST-18964] Fixes empty trackerId for bitstream download feature

This commit is contained in:
Vincenzo Mecca
2025-03-26 20:23:21 +01:00
parent e4e5255a46
commit ab9cbea7c3

View File

@@ -145,7 +145,7 @@ export class MatomoService {
*/ */
private appendTrackerId(url: string, visitorId: string) { private appendTrackerId(url: string, visitorId: string) {
const updatedURL = new URL(url); const updatedURL = new URL(url);
if (visitorId != null) { if (isNotEmpty(visitorId)) {
updatedURL.searchParams.append('trackerId', visitorId); updatedURL.searchParams.append('trackerId', visitorId);
} }
return updatedURL.toString(); return updatedURL.toString();