mirror of
https://github.com/WordPress/WordPress.git
synced 2025-04-03 18:47:05 +02:00
Ensure that wp.media.view.settings.post
is set before accessing the post's id
Avoids JS error in cases where media-editor is loaded individually instead of with the whole `wp_enqueue_media()` process. fixes #27836. props nacin Built from https://develop.svn.wordpress.org/trunk@28149 git-svn-id: http://core.svn.wordpress.org/trunk@27980 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
dd8531a3b3
commit
b9eb0f72e3
@ -535,7 +535,7 @@
|
||||
link: 'post',
|
||||
size: 'thumbnail',
|
||||
order: 'ASC',
|
||||
id: wp.media.view.settings.post.id,
|
||||
id: wp.media.view.settings.post && wp.media.view.settings.post.id,
|
||||
orderby : 'menu_order ID'
|
||||
}
|
||||
});
|
||||
|
2
wp-includes/js/media-editor.min.js
vendored
2
wp-includes/js/media-editor.min.js
vendored
File diff suppressed because one or more lines are too long
Loading…
Reference in New Issue
Block a user