Skip Navigation

[Closed] warning: in_array() expects parameter 2 to be array, null given

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

No supporters are available to work today on Toolset forum. Feel free to create tickets and we will handle it as soon as we are online. Thank you for your understanding.

This topic contains 1 reply, has 2 voices.

Last updated by Christopher Amirian 1 year, 6 months ago.

Assisted by: Christopher Amirian.

Author
Posts
#2481049

hej toolset.
i'm trying to delete a media file …

Warning: in_array() expects parameter 2 to be array, string given in /html/wordpress/wp-content/plugins/wp-views/application/controllers/cache/meta/invalidator.php on line 155

Fatal error: Uncaught Error: [] operator not supported for strings in /html/wordpress/wp-content/plugins/wp-views/application/controllers/cache/meta/invalidator.php:159 Stack trace: #0 /html/wordpress/wp-content/plugins/wp-views/application/controllers/cache/meta/invalidator.php(102): OTGS\Toolset\Views\Controller\Cache\Meta\InvalidatorBase->maybe_update_hidden_transient('_wp_trash_meta_...') #1 /html/wordpress/wp-includes/class-wp-hook.php(307): OTGS\Toolset\Views\Controller\Cache\Meta\InvalidatorBase->maybe_update_transient(2947243, 294751, '_wp_trash_meta_...', 'inherit') #2 /html/wordpress/wp-includes/class-wp-hook.php(331): WP_Hook->apply_filters(NULL, Array) #3 /html/wordpress/wp-includes/plugin.php(476): WP_Hook->do_action(Array) #4 /html/wordpress/wp-includes/meta.php(154): do_action('added_post_meta', 2947243, 294751, '_wp_trash_meta_...', 'inherit') #5 /html/wordpress/wp-includes/post.php(2439): add_metadata('post', 294751, '_wp_trash_meta_...', 'inherit', false) #6 /html/wordpress/wp-includes/post.php(3569): ad in /html/wordpress/wp-content/plugins/wp-views/application/controllers/cache/meta/invalidator.php on line 159

any idea? any chance to maybe_update_hidden_transient?

best,
s

#2482095

Christopher Amirian
Supporter

Languages: English (English )

Hi there,

Would you please delete the media file from WordPress Dashboard > Media?

Also, make sure you clear any sort of cache that you might have and install the plugin below and do the regenerate functionality:

https://wordpress.org/plugins/regenerate-thumbnails/

For the transient one you can check this:

hidden link

Finally, you need to make sure that no instance of the image is already in use somewhere as a post featured image or attached to a cusotm post.

Thank you.

The topic ‘[Closed] warning: in_array() expects parameter 2 to be array, null given’ is closed to new replies.