Unable to delete a post on Wordpress because of WP Meta SEO

I have a strange problem. First of all here is the relevant information:

Ubuntu 18.04 LTS with all updates installed
Wordpress 5.0.3 with all plugins updated to latest version
Latest version of the Wordpress theme installed

Basically what happens is when I try and delete a specific post in the Wordpress admin panel I am shown an HTTP 500 error. When I look in my error log this is what I see:

[Wed Jan 23 18:30:19.843887 2019] [proxy_fcgi:error] [pid 1059:tid 140215319881472] [client 86.8.46.191:65533] AH01071: Got error ‘PHP message: PHP Fatal error: Uncaught Error: Call to a member function getAttribute() on array in /var/www/html/domain.com/public_html/wp-content/plugins/wp-meta-seo/inc/class.metaseo-image-list-table.php:2010\nStack trace:\n#0 /var/www/html/domain.com/public_html/wp-includes/class-wp-hook.php(286): MetaSeoImageListTable::deletePost(149)\n#1 /var/www/html/domain.com/public_html/wp-includes/class-wp-hook.php(310): WP_Hook->apply_filters(NULL, Array)\n#2 /var/www/html/domain.com/public_html/wp-includes/plugin.php(453): WP_Hook->do_action(Array)\n#3 /var/www/html/domain.com/public_html/wp-includes/post.php(2705): do_action(‘delete_post’, 149)\n#4 /var/www/html/domain.com/public_html/wp-admin/post.php(275): wp_delete_post(149, true)\n#5 {main}\n thrown in /var/www/html/domain.com/public_html/wp-content/plugins/wp-meta-seo/inc/class.metaseo-image-list-table.php on line 2010\n’, referer: https://www.domain.com/wp-admin/edit.php?post_status=trash&post_type=post

All I have done is remove the domain name from the log. The rest is how it appears in my Apache error log. If you need any more information then please let me know as I would really like to get this fixed.

2 Replies

The HTTP 500 error is an internal server error. While it does happen on WordPress, it's not confined to it. This can happen with any server.

You've taken the important first step, which is checking your Apache error logs.

With WordPress, the error can be caused by either (or both) a corrupted .htaccess file or PHP Memory Limit. It can also be caused by plugins. The output you provided mentions both PHP and plugins, so I'd like to provide you with multiple fixes you can try.

On a third party site, I found an excellent article detailing how to fix this error specifically in WordPress:

Fix the Internal Server Error in Wordpress

My recommendation is to go through the article in that link, and focus on the fixes that deal directly with PHP and plugins. Since this is a public post, please feel free to update us with your results so that other users that might be experiencing this issue can benefit from it.

The HTTP 500 mistake is an interior server blunder. While it happens on WordPress, it's not bound to it. This can occur with any server.

Go to the Plugins > WP Meta SEO > Deactivate > Delete
If you choose to install it later all your SEO data will remain in place (database stored)

Reply

Please enter an answer
Tips:

You can mention users to notify them: @username

You can use Markdown to format your question. For more examples see the Markdown Cheatsheet.

> I’m a blockquote.

I’m a blockquote.

[I'm a link] (https://www.google.com)

I'm a link

**I am bold** I am bold

*I am italicized* I am italicized

Community Code of Conduct