Title: PHP Deprecated Error
Last modified: June 21, 2024

---

# PHP Deprecated Error

 *  Resolved [Qilin](https://wordpress.org/support/users/qilin2000/)
 * (@qilin2000)
 * [1 year, 11 months ago](https://wordpress.org/support/topic/php-deprecated-error-18/)
 * Hello there,
 * My website has debug mode enabled. After a recent upgrade, the plugin frequently
   reports errors, with the following error message:
 * **Function has_cap was called with an argument that is deprecated since version
   2.0.0! Usage of user levels is deprecated. Use capabilities instead. in example.
   com\wp-includes\functions.php on line 6078**
 * It may be related to the recent upgrade of the WooCommerce plugin, I’m not sure.
   However, after deactivating WooCommerce, the plugin still reports errors. After
   deactivating this plugin, the errors are gone.
 * Please look into it, thanks.
 * Qilin

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

 *  Plugin Author [JWardee](https://wordpress.org/support/users/wardee/)
 * (@wardee)
 * [1 year, 11 months ago](https://wordpress.org/support/topic/php-deprecated-error-18/#post-17842061)
 * Hi Qilin,
 * `has_cap` isn’t used anywhere in the plugin. Could you share the stack trace 
   in your logs so we can see what led up to the error rather than just the error
   itself. Also what version of WordPress and PHP are you using?
 * Thanks,
   James
 *  Thread Starter [Qilin](https://wordpress.org/support/users/qilin2000/)
 * (@qilin2000)
 * [1 year, 11 months ago](https://wordpress.org/support/topic/php-deprecated-error-18/#post-17842711)
 * Hi James,
 * I fixed the issue. There are two options in the settings, **User capability needed
   to see logs** and **User capability needed to edit settings**, I recently changed
   these two options, which caused an error, and after resetting them, the error
   message disappeared.
 * I use PHP 7.4.33 and WP 6.5.4
 * Qilin

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

The topic ‘PHP Deprecated Error’ is closed to new replies.

 * ![](https://ps.w.org/wp-mail-catcher/assets/icon.svg?rev=2221293)
 * [Mail logging - WP Mail Catcher](https://wordpress.org/plugins/wp-mail-catcher/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/wp-mail-catcher/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/wp-mail-catcher/)
 * [Active Topics](https://wordpress.org/support/plugin/wp-mail-catcher/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wp-mail-catcher/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wp-mail-catcher/reviews/)

 * 2 replies
 * 2 participants
 * Last reply from: [Qilin](https://wordpress.org/support/users/qilin2000/)
 * Last activity: [1 year, 11 months ago](https://wordpress.org/support/topic/php-deprecated-error-18/#post-17842711)
 * Status: resolved