Force Plugin Updates: “Update Failed: Plugin update failed.” after update one plugin

Posted by Ramesh Singh | Updated on

I solved my issue, so for those people who want to achieve the same thing about forcing updates using EDD, here’s the solution (or at least worked for me):

First of all, when you update a plugin via the plugins page, it does via AJAX, so I had to read the /wp-admin/includes/ajax-actions.php file, and inside of the wp_ajax_update_plugin() function found that was executing wp_update_plugins() function, so I realized that was overwriting the update_plugins site transient.

At this point, I thought my filters were executing but no, the thing is I was executing those filters inside of the current_screen action, and when the wp_update_plugins() function was called from wp_ajax_update_plugin(), it wasn’t listen to them.

So I had to create new filters and execute them when my class is invoked.

And that’s it, problem solved. Hope you can find this useful.


If you like this question & answer and want to contribute, then write your question & answer and email to freewebmentor[@]gmail.com. Your question and answer will appear on FreeWebMentor.com and help other developers.

Related Questions & Answers