Title: Github Snippet(s) Appreciated
Last modified: July 4, 2019

---

# Github Snippet(s) Appreciated

 *  [jetxpert](https://wordpress.org/support/users/jetxpert/)
 * (@jetxpert)
 * [6 years, 11 months ago](https://wordpress.org/support/topic/github-snippets-appreciated/)
 * Hi there!
 * Fabulous plugin. Clean, simple, effective. As you probably know, the WP Site 
   Health check tool generates – in many cases – false positives. Your plugin helps
   solve most of them.
 * Based on the above, in addition to using your plugin, would it be possible to
   provide a snippet (PHP Code) that will allow us to deactivate or disable the 
   variable that may be causing the false positive? In our case, we had to deactivate“
   Scheduled Events.” Can you provide a snippet for this one to start with? 🙂
 * Also, it would be much appreciated if you can publish the snippets in Github.
 * By the way, it’s a known issue that WP’s Site Health check tool works well only
   when using WP_CRON not a Real Job Cron. Click here for more info (WP aware of
   the issue and working on a solution): [https://core.trac.wordpress.org/ticket/47223](https://core.trac.wordpress.org/ticket/47223)
 * Thank you!

Viewing 1 replies (of 1 total)

 *  Thread Starter [jetxpert](https://wordpress.org/support/users/jetxpert/)
 * (@jetxpert)
 * [6 years, 11 months ago](https://wordpress.org/support/topic/github-snippets-appreciated/#post-11701476)
 * Follow-up …
 * Performed some research after posting above inquiry. Link below solved above 
   request, but would be great if you can review it and perhaps generate the snippet(
   s) requested – and posting them on Github. I’m not a developer, just a plain ‘
   ol WP user. Your decision, of course!
 * [How to Disable Tests in the WordPress Site Health Check Tool](https://wearnhardt.com/2019/05/how-to-disable-tests-in-the-wordpress-site-health-check-tool/)
 * Based on the above, the snippet created to disable **Scheduled Events** is:
 *     ```
       function prefix_remove_scheduled_events( $tests ) {
           unset( $tests['direct']['scheduled_events'] );
           return $tests;
       }
       add_filter( 'site_status_tests', 'prefix_remove_scheduled_events' );
       ```
   
 * Above works (confirmed). We no longer get a Scheduled Event error message triggered
   due to using a Real Cron Job in lieu of WP_CRON.
 * Input appreciated. Thank you!

Viewing 1 replies (of 1 total)

The topic ‘Github Snippet(s) Appreciated’ is closed to new replies.

 * ![](https://ps.w.org/site-health-manager/assets/icon.svg?rev=2090933)
 * [Site Health Manager](https://wordpress.org/plugins/site-health-manager/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/site-health-manager/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/site-health-manager/)
 * [Active Topics](https://wordpress.org/support/plugin/site-health-manager/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/site-health-manager/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/site-health-manager/reviews/)

## Tags

 * [false positive](https://wordpress.org/support/topic-tag/false-positive/)
 * [snippet](https://wordpress.org/support/topic-tag/snippet/)
 * [tool](https://wordpress.org/support/topic-tag/tool/)

 * 1 reply
 * 1 participant
 * Last reply from: [jetxpert](https://wordpress.org/support/users/jetxpert/)
 * Last activity: [6 years, 11 months ago](https://wordpress.org/support/topic/github-snippets-appreciated/#post-11701476)
 * Status: not resolved