mirror of
https://github.com/foomo/sesamy-go.git
synced 2025-10-16 12:35:43 +00:00
fix: transform debug mode
This commit is contained in:
parent
dced802d6a
commit
f8fcacca2a
@ -20,12 +20,13 @@ func MPv2(source gtag.Payload, target any) error {
|
||||
return errors.Wrap(err, "failed to unmarshal source")
|
||||
}
|
||||
|
||||
// transorm map to match mpv2 format
|
||||
// transform map to match mpv2 format
|
||||
targetData := map[string]any{
|
||||
"client_id": source.ClientID,
|
||||
"user_id": source.UserID,
|
||||
"non_personalized_ads": source.NonPersonalizedAds,
|
||||
"timestamp_micros": source.SST.TFT,
|
||||
"debug_mode": source.IsDebug,
|
||||
}
|
||||
if source.SST != nil && source.SST.TFT != nil {
|
||||
targetData["timestamp_micros"] = gtag.Get(source.SST.TFT) + "000"
|
||||
|
||||
Loading…
Reference in New Issue
Block a user