Title: WP_DEBUG error with register_uninstall_hook
Last modified: August 20, 2016

---

# WP_DEBUG error with register_uninstall_hook

 *  Resolved [disagree](https://wordpress.org/support/users/disagree/)
 * (@disagree)
 * [13 years, 3 months ago](https://wordpress.org/support/topic/wp_debug-error-with-register_uninstall_hook/)
 * If you turn on WP_DEBUG, you’ll get
 *     ```
       Notice: register_uninstall_hook was called <strong>incorrectly</strong>. Only a static class method or function can be used in an uninstall hook. Please see <a href="http://codex.wordpress.org/Debugging_in_WordPress">Debugging in WordPress</a> for more information. (This message was added in version 3.1.) in /var/www/wp-includes/functions.php on line 2758
       ```
   
 * based on line 55 : `register_uninstall_hook(__FILE__, array(&$this, 'deactivate'));`
 * [http://wordpress.org/extend/plugins/update-notifications-manager/](http://wordpress.org/extend/plugins/update-notifications-manager/)

Viewing 2 replies - 1 through 2 (of 2 total)

 *  Thread Starter [disagree](https://wordpress.org/support/users/disagree/)
 * (@disagree)
 * [13 years, 3 months ago](https://wordpress.org/support/topic/wp_debug-error-with-register_uninstall_hook/#post-3506214)
 * I think this might be the solution :
    `register_uninstall_hook(__FILE__, &$this-
   >deactivate);`
 * But please verify
 *  Plugin Author [GeekPress](https://wordpress.org/support/users/geekpress/)
 * (@geekpress)
 * [12 years, 5 months ago](https://wordpress.org/support/topic/wp_debug-error-with-register_uninstall_hook/#post-3506629)
 * Hi,
 * The new version (1.1.2) fix this bug.
 * Thanks for your report 😉

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘WP_DEBUG error with register_uninstall_hook’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/update-notifications-manager.svg)
 * [Update Notifications Manager](https://wordpress.org/plugins/update-notifications-manager/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/update-notifications-manager/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/update-notifications-manager/)
 * [Active Topics](https://wordpress.org/support/plugin/update-notifications-manager/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/update-notifications-manager/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/update-notifications-manager/reviews/)

 * 2 replies
 * 2 participants
 * Last reply from: [GeekPress](https://wordpress.org/support/users/geekpress/)
 * Last activity: [12 years, 5 months ago](https://wordpress.org/support/topic/wp_debug-error-with-register_uninstall_hook/#post-3506629)
 * Status: resolved