Make WordPress Core

Opened 11 months ago

Closed 3 months ago

Last modified 3 months ago

#59307 closed defect (bug) (worksforme)

Urgent, Uncaught TypeError: this.activateMode is not a function

Reported by: jjproitech's profile jjproitech Owned by:
Milestone: Priority: normal
Severity: critical Version: 6.3.1
Component: Media Keywords:
Focuses: ui, javascript Cc:

Description

It's very urgent. There is no response when clicking the media button on the add/edit article page.
Showing an error every click on the media button:
Uncaught TypeError: this.activateMode is not a function

at media-views.min.js?ver=6.3.1:2:59604
at It (provider.js:2:586804)
at Function.ma (provider.js:2:621991)
at n._createModes (media-views.min.js?ver=6.3.1:2:59564)
at n.initialize (media-views.min.js?ver=6.3.1:2:58973)
at n.initialize (media-views.min.js?ver=6.3.1:2:79857)
at n.initialize (media-views.min.js?ver=6.3.1:2:73432)
at n.initialize (media-views.min.js?ver=6.3.1:2:63143)
at h.View (load-scripts.php?c=1&load%5Bchunk_0%5D=wp-polyfill-inert,regenerator-runtime,wp-polyfill,wp-hooks,jquery-core,jquery-migrate,utils,jquery-ui-core,jquery-ui-mouse,jquer&load%5Bchunk_1%5D=y-ui-sortable,underscore,backbone,wp-util,wp-backbone,media-models,moxiejs,plupload&ver=6.3.1:151:14648)
at n.constructor (load-scripts.php?c=1&load%5Bchunk_0%5D=wp-polyfill-inert,regenerator-runtime,wp-polyfill,wp-hooks,jquery-core,jquery-migrate,utils,jquery-ui-core,jquery-ui-mouse,jquer&load%5Bchunk_1%5D=y-ui-sortable,underscore,backbone,wp-util,wp-backbone,media-models,moxiejs,plupload&ver=6.3.1:155:2602)

Attachments (1)

Screenshot from 2023-09-07 16-00-33.png (179.2 KB) - added by jjproitech 11 months ago.
Urgent

Download all attachments as: .zip

Change History (4)

This ticket was mentioned in Slack in #core-media by antpb. View the logs.


3 months ago

#2 @antpb
3 months ago

  • Milestone Awaiting Review deleted
  • Resolution set to worksforme
  • Status changed from new to closed

Hi @jjproitech are you still seeing this issue? I've set up a site with the latest WordPress and WooCommerce with no issues opening the Media library. Have you tried disabling other plugins to eliminate the possibility of those getting in the way?

I'm going to close this as it seems more related to WooCommerce and also seems to be working currently.

#3 @joedolson
3 months ago

This issue has come up before; it's caused because both Lodash and Underscores use the _. Here are some prior discussions that might be helpful:

https://github.com/WordPress/gutenberg/discussions/36768

https://stackoverflow.com/questions/63672622/typeerror-this-activatemode-is-not-a-function-gutenberg-wordpress/63672911#63672911

Note: See TracTickets for help on using tickets.