Title: deprecated log
Last modified: August 22, 2016

---

# deprecated log

 *  [ladygeekgeek](https://wordpress.org/support/users/ladygeekgeek/)
 * (@ladygeekgeek)
 * [11 years, 8 months ago](https://wordpress.org/support/topic/deprecated-log/)
 * Hi there – thanks for a great plugin. I’m getting a deprecated call error though
   and wonder if there is something I need to do to fix this. It’s on a clean WP
   install and I’ve not changed any settings in the Admin menu editor yet:
 * Argument in current_user_can()
    An admin menu page is using user levels instead
   of capabilities. There is likely a related log item with specifics.
 * Usage of user levels by plugins and themes is deprecated. Use roles and capabilities
   instead.
    Deprecated in version 2.0.
 * Count:14
 * Many thanks
 * [https://wordpress.org/plugins/admin-menu-editor/](https://wordpress.org/plugins/admin-menu-editor/)

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

 *  Plugin Author [Janis Elsts](https://wordpress.org/support/users/whiteshadow/)
 * (@whiteshadow)
 * [11 years, 8 months ago](https://wordpress.org/support/topic/deprecated-log/#post-5372472)
 * Usually this warning message shows up when one of your other plugins (or the 
   theme) relies on user levels. Admin Menu Editor doesn’t normally use them on 
   its own, but it may be forced to check user levels if something creates a menu
   item with a user level instead of a capability.
 * It’s strange that this warning would show up on a clean install. Have you installed
   a custom theme or any other plugins aside from AME? Are there any relevant messages
   in your PHP error log?
 *  Thread Starter [ladygeekgeek](https://wordpress.org/support/users/ladygeekgeek/)
 * (@ladygeekgeek)
 * [11 years, 8 months ago](https://wordpress.org/support/topic/deprecated-log/#post-5372478)
 * Thanks for the quick reply.
    You were right – the theme had the conditional statement:
 *     ```
       if (!is_admin())
       ```
   
 * I changed this to:
 *     ```
       if ( !current_user_can('edit_posts') )
       ```
   
 * And the error is gone now.
    Thanks again for your help!
 * Actually this doesn’t do what I want – which is to only load scripts on the frontend.
   Perhaps it’s safe to ignore the warning…
 *  Plugin Author [Janis Elsts](https://wordpress.org/support/users/whiteshadow/)
 * (@whiteshadow)
 * [11 years, 8 months ago](https://wordpress.org/support/topic/deprecated-log/#post-5372518)
 * > You were right – the theme had the conditional statement:
   >  if (!is_admin())
 * Interesting, normally `is_admin()` wouldn’t trigger a warning.
 * > Perhaps it’s safe to ignore the warning…
 * It’s relatively safe. The warning indicates that a plugin/theme might be doing
   something wrong, but usually it won’t break the site.

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

The topic ‘deprecated log’ is closed to new replies.

 * ![](https://ps.w.org/admin-menu-editor/assets/icon-128x128.png?rev=1418604)
 * [Admin Menu Editor](https://wordpress.org/plugins/admin-menu-editor/)
 * [Support Threads](https://wordpress.org/support/plugin/admin-menu-editor/)
 * [Active Topics](https://wordpress.org/support/plugin/admin-menu-editor/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/admin-menu-editor/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/admin-menu-editor/reviews/)

 * 3 replies
 * 2 participants
 * Last reply from: [Janis Elsts](https://wordpress.org/support/users/whiteshadow/)
 * Last activity: [11 years, 8 months ago](https://wordpress.org/support/topic/deprecated-log/#post-5372518)
 * Status: not resolved