Closed pattonwebz closed 4 months ago
There is a function in the plugin that triggers a frontend validation scan on a post. It's triggered by template_redirect
hook.
The block editor, when opened, makes a call to determine the available templates the post_type can use which triggers that action and the validation scan. If the editor is opened for a new post it will be an auto-draft and have no accessible page yet so the validate fails resulting in a logged error and then the plugin makes the assumption that the site is password protected.
Error that is thrown:
[19-Mar-2024 18:08:33 UTC] PHP Warning: file_get_contents(http://local.testsite.test/?p=62642&edac_cache=1710871710): Failed to open stream: HTTP request failed! HTTP/1.1 404 Not Found
in /var/www/html/wp-content/plugins/accessibility-checker/includes/simplehtmldom/simple_html_dom.php on line 79
Please give us a description of what happened.
When you create a new post in the block editor a scan is triggered on the auto draft resulting in an an error that causes the password protected message to appear until a post is saved and a scan on a valid page is successful.
Please describe what you expected to happen and why.
No scan is triggered on an autodraft with no content.
How can we reproduce this behavior?
Technical info