File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -78,6 +78,10 @@ public function admin_init() {
7878 $ this ->get_method ( 'media_library_bulk_action ' )
7979 );
8080
81+ add_action ( 'admin_action_-1 ' ,
82+ $ this ->get_method ( 'media_library_bulk_action ' )
83+ );
84+
8185 add_filter ( 'manage_media_columns ' ,
8286 $ this ->get_method ( 'add_media_columns ' )
8387 );
@@ -319,7 +323,13 @@ public function ajax_optimization_statistics() {
319323 public function media_library_bulk_action () {
320324 check_admin_referer ( 'bulk-media ' );
321325
322- if ( empty ( $ _REQUEST ['media ' ] ) || ! is_array ( $ _REQUEST ['media ' ] ) ) {
326+ if ( empty ( $ _REQUEST ['action ' ] ) || (
327+ $ _REQUEST ['action ' ] != 'tiny_bulk_action ' &&
328+ $ _REQUEST ['action2 ' ] != 'tiny_bulk_action ' ) ) {
329+ return ;
330+ }
331+
332+ if ( empty ( $ _REQUEST ['media ' ] ) || ( ! $ _REQUEST ['media ' ] ) ) {
323333 return ;
324334 }
325335
You can’t perform that action at this time.
0 commit comments