s.clearvars function not working after new library update (16.4)

Avatar

Avatar
Validate 1
Level 1
guidov61672237
Level 1

Like

1 like

Total Posts

15 posts

Correct reply

1 solution
Top badges earned
Validate 1
Boost 1
Affirm 1
View profile

Avatar
Validate 1
Level 1
guidov61672237
Level 1

Like

1 like

Total Posts

15 posts

Correct reply

1 solution
Top badges earned
Validate 1
Boost 1
Affirm 1
View profile
guidov61672237
Level 1

20-08-2016

Hello,

It appears that after library update the following script which I set in the condition of multiple rules (because our platform is an SPA) is not working anymore. Is there a solution for this?

var s = _satellite.getToolsByType('sc')[0].getS();
s.clearVars();
return true;

Regards,

Guido

Accepted Solutions (1)

Accepted Solutions (1)

Avatar

Avatar
Validate 1
Level 1
guidov61672237
Level 1

Like

1 like

Total Posts

15 posts

Correct reply

1 solution
Top badges earned
Validate 1
Boost 1
Affirm 1
View profile

Avatar
Validate 1
Level 1
guidov61672237
Level 1

Like

1 like

Total Posts

15 posts

Correct reply

1 solution
Top badges earned
Validate 1
Boost 1
Affirm 1
View profile
guidov61672237
Level 1

23-08-2016

Thanks for the quick response. I've send you a PM.

Answers (3)

Answers (3)

Avatar

Avatar
Validate 10
Level 10
ParitMittal
Level 10

Likes

93 likes

Total Posts

817 posts

Correct reply

349 solutions
Top badges earned
Validate 10
Validate 1
Boost 50
Boost 5
Boost 3
View profile

Avatar
Validate 10
Level 10
ParitMittal
Level 10

Likes

93 likes

Total Posts

817 posts

Correct reply

349 solutions
Top badges earned
Validate 10
Validate 1
Boost 50
Boost 5
Boost 3
View profile
ParitMittal
Level 10

23-08-2016

Hi ,

Please share your DTM account details & URL of the webiste in a mail (pamittal@adobe.com) or in a private message so that we can debug the issue at our end.

Thanks & Regards

Parit Mittal

Avatar

Avatar
Validate 1
Level 1
guidov61672237
Level 1

Like

1 like

Total Posts

15 posts

Correct reply

1 solution
Top badges earned
Validate 1
Boost 1
Affirm 1
View profile

Avatar
Validate 1
Level 1
guidov61672237
Level 1

Like

1 like

Total Posts

15 posts

Correct reply

1 solution
Top badges earned
Validate 1
Boost 1
Affirm 1
View profile
guidov61672237
Level 1

22-08-2016

@Parmit

It seems that it has nothing to do with the new libary version. 

Our website is an SPA and we measure page loads by using event based rules. Each time afunctional page load takes place we generte a random ID in our dataLayer and we use this as a trigger for the page load rule. In this rule I use the above script. The script works fine, but not in the case I reload the page. Then I get the following error:

SATELLITE: Condition for rule "AA: page load" not met. Error: Cannot read property 'clearVars' of null

It seems this prevents the rule from firing. Can you please tell me what is going wrong?

Regards,

 

Guido

Avatar

Avatar
Validate 10
Level 10
ParitMittal
Level 10

Likes

93 likes

Total Posts

817 posts

Correct reply

349 solutions
Top badges earned
Validate 10
Validate 1
Boost 50
Boost 5
Boost 3
View profile

Avatar
Validate 10
Level 10
ParitMittal
Level 10

Likes

93 likes

Total Posts

817 posts

Correct reply

349 solutions
Top badges earned
Validate 10
Validate 1
Boost 50
Boost 5
Boost 3
View profile
ParitMittal
Level 10

22-08-2016

Hi ,

We tried the same at our end and the below piece of code is working at our end with AppMeasurement library version 1.6.4.Please share your DTM account details in a mail (pamittal@adobe.com) or in a private message so that we can debug the issue at our end.

var s = _satellite.getToolsByType('sc')[0].getS();
s.clearVars();
return true;

Thanks & Regards

Parit Mittal