If the user is using an adblocker to block the service, or if the ShareThis servers were to go down, then it should not interrupt other JS on the page. This is currently not the case - we get a 'stLight is undefined' error.

Patch forthcoming

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

dalin’s picture

Status: Active » Needs review
FileSize
931 bytes
timfernihough’s picture

Status: Needs review » Reviewed & tested by the community
FileSize
648 bytes

@dalin,

I've downloaded and tested this and works well, marking RBTC.

In my case, I'm working with a responsive theme that relies heavily on Javascript to function and we are finding that the client this project is for has an audience with very high security settings in their browsers and in some cases it prevents ShareThis from loading. This cascades and causes the entire theme to break as a result because of the stLight error.

I had to modify it to work with the most recent stable version (7.x-2.5) as that is what we're using in our install profile, so I've uploaded a second patch here for anyone who may need it for their make file.

Jerenus’s picture

Status: Reviewed & tested by the community » Needs work
 ~/sharethis $ patch -p1 < sharethis_js_undefined_1845134_1.patch 
patching file sharethis.module
Hunk #1 FAILED at 473.
1 out of 1 hunk FAILED -- saving rejects to file sharethis.module.rej
Jerenus’s picture

Jslint's suggestion.

Jerenus’s picture

Status: Needs work » Needs review
RobLoach’s picture

Status: Needs review » Reviewed & tested by the community

Looks good! I'll hopefully be able to commit today.

RobLoach’s picture

Status: Reviewed & tested by the community » Fixed
Jerenus’s picture

Thank you for your encouragement. ;)

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.