Title: wp_enqueue_script() was called incorrectly
Last modified: December 8, 2021

---

# wp_enqueue_script() was called incorrectly

 *  [ArtGoddess](https://wordpress.org/support/users/artgoddess/)
 * (@artgoddess)
 * [4 years, 5 months ago](https://wordpress.org/support/topic/wp_enqueue_script-was-called-incorrectly-19/)
 * Hello,
 * With debug mode activated, I can see this PHP warning in `/wp-admin/widgets.php`:
 * `Notice: wp_enqueue_script() was called incorrectly. "wp-editor" script should
   not be enqueued together with the new widgets editor (wp-edit-widgets or wp-customize-
   widgets). Please see Debugging in WordPress for more information. (This message
   was added in version 5.8.0.) in /home/user/domain.com/wp-includes/functions.php
   on line 5663`
 * No plugins activated.
 * PHP 8
    WordPress 5.8.2 Twenty Twenty-One 1.4
 * What am I doing wrong? Many thanks!

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

 *  Moderator [James Huff](https://wordpress.org/support/users/macmanx/)
 * (@macmanx)
 * [4 years, 5 months ago](https://wordpress.org/support/topic/wp_enqueue_script-was-called-incorrectly-19/#post-15145442)
 * This may be a plugin or theme conflict. Please attempt to disable all plugins,
   and switch to the default Twenty Twenty-One theme. If the problem goes away, 
   enable them one by one to identify the source of the problem.
 * If you can install plugins, install [Health Check](https://wordpress.org/plugins/health-check/).
   On the troubleshooting tab, you can click the button to disable all plugins and
   change the theme for you, while you’re still logged in, **without affecting normal
   visitors to your site**.
 *  Thread Starter [ArtGoddess](https://wordpress.org/support/users/artgoddess/)
 * (@artgoddess)
 * [4 years, 5 months ago](https://wordpress.org/support/topic/wp_enqueue_script-was-called-incorrectly-19/#post-15146334)
 * It is not a matter of plugins.
 * I am viewing this message in the backend with DEBUG enabled.
 * I don’t have any plugins activated at all.
 * Please, let me know if this bug is reported on a ticket.
 * Many thanks.
 *  Moderator [James Huff](https://wordpress.org/support/users/macmanx/)
 * (@macmanx)
 * [4 years, 5 months ago](https://wordpress.org/support/topic/wp_enqueue_script-was-called-incorrectly-19/#post-15148649)
 * Ah yes, here you go: [https://core.trac.wordpress.org/ticket/53569](https://core.trac.wordpress.org/ticket/53569)
 *  Thread Starter [ArtGoddess](https://wordpress.org/support/users/artgoddess/)
 * (@artgoddess)
 * [4 years, 5 months ago](https://wordpress.org/support/topic/wp_enqueue_script-was-called-incorrectly-19/#post-15148702)
 * Nice!
 * [@macmanx](https://wordpress.org/support/users/macmanx/) I’m not used to trac.
   wordpress.org, so sorry for asking. Has this been solved in 5.8.2 or hasn’t been
   fixed yet? I can see the ticket is closed.
 * Many thanks for your guidance.
 *  Moderator [James Huff](https://wordpress.org/support/users/macmanx/)
 * (@macmanx)
 * [4 years, 5 months ago](https://wordpress.org/support/topic/wp_enqueue_script-was-called-incorrectly-19/#post-15148764)
 * Allegedly this was fixed in 5.8.2.
 * There is a reply there that leads me to believe someone has not found it as such
   though.
 * I recommend replying in a comment there so the developers are aware of your experience
   as well.
 *  Thread Starter [ArtGoddess](https://wordpress.org/support/users/artgoddess/)
 * (@artgoddess)
 * [4 years, 5 months ago](https://wordpress.org/support/topic/wp_enqueue_script-was-called-incorrectly-19/#post-15148778)
 * [@macmanx](https://wordpress.org/support/users/macmanx/) done. I hope this helps.
   ☺️
 *  Moderator [James Huff](https://wordpress.org/support/users/macmanx/)
 * (@macmanx)
 * [4 years, 5 months ago](https://wordpress.org/support/topic/wp_enqueue_script-was-called-incorrectly-19/#post-15148788)
 * Thanks!
 * The developers will reply there if they need any further info.
 *  Thread Starter [ArtGoddess](https://wordpress.org/support/users/artgoddess/)
 * (@artgoddess)
 * [4 years, 4 months ago](https://wordpress.org/support/topic/wp_enqueue_script-was-called-incorrectly-19/#post-15187119)
 * Hi [@macmanx](https://wordpress.org/support/users/macmanx/) nobody has reacted
   to the ticket:
 * [https://core.trac.wordpress.org/ticket/53569](https://core.trac.wordpress.org/ticket/53569)
 * The issue is still happening and I suspect that this is a behaviour that arises
   from WordPress itself, no matter which plugins or themes we are using.
 * What is more, maybe I’m bothering some plugin authors without the need:
 * [https://wordpress.org/support/topic/twentig-widgets-wp_enqueue_script-was-called-incorrectly/](https://wordpress.org/support/topic/twentig-widgets-wp_enqueue_script-was-called-incorrectly/)
 * [https://wordpress.org/support/topic/dmca-badge-and-widgets/](https://wordpress.org/support/topic/dmca-badge-and-widgets/)
 * I kindly ask you how to report this correctly, as nobody seems to bother about
   this warning.
 * Please, do let me know. Many thanks!

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

The topic ‘wp_enqueue_script() was called incorrectly’ is closed to new replies.

## Tags

 * [wp_enqueue_script](https://wordpress.org/support/topic-tag/wp_enqueue_script/)

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 8 replies
 * 2 participants
 * Last reply from: [ArtGoddess](https://wordpress.org/support/users/artgoddess/)
 * Last activity: [4 years, 4 months ago](https://wordpress.org/support/topic/wp_enqueue_script-was-called-incorrectly-19/#post-15187119)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
