Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Disable the ad block nag for ad-free projects #4329

merged 3 commits into from Jul 16, 2018


Copy link

@davidfischer davidfischer commented Jul 5, 2018

This PR disables the ad block nag if the project is ad free by setting a flag in READTHEDOCS_DATA. There is still a server side API call to get the ad which checks whether a user or project has gone Gold. This call can be blocked by some ad blockers.

There will be a corresponding PR in the sphinx build extensions:

Fixes #4218 for ad-free projects. Ad-free users will still need to disable their ad blocker.

@davidfischer davidfischer requested a review from Jul 5, 2018
Copy link

@ericholscher ericholscher left a comment

Ah, this addresses my other comment in the previous PR :)


@davidfischer davidfischer merged commit 09f19a4 into master Jul 16, 2018
1 check passed
@davidfischer davidfischer deleted the davidfischer/no-nag-for-adfree-projects branch Jul 16, 2018
@@ -261,7 +261,7 @@ function init() {
error: function (xhr, textStatus, errorThrown) {
console.error('Error loading Read the Docs promo');

if (xhr && xhr.status === 404 && rtd.api_host === '') {
if (!rtddata.ad_free && xhr && xhr.status === 404 && rtd.api_host === '') {
Copy link
Contributor Author

@davidfischer davidfischer Aug 31, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should have been rtd.ad_free. How did this ever work?


Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

2 participants