WordPress Plugins Issue — UASORT()


“Warning: uasort expects …”

That was the nerve-wrecking message I saw when I try to add a new plugin on my WordPress site.  For me, I think that message should be appropriately classified as “Error – Adding Plugins No Longer Possible”, for you are totally dead in the water as far as getting new plugins is concerned. I have included the full warning message at the bottom of this post for your reference.

Cold sweat trickled down my forehead after I tried many different steps like rebooting my machine and uninstalling the most recent plugins to no avail. The problem won’t go away. I hit the panic button with InMotionHosting, my web hosting provider, for help. The support guy, after close to 15 minutes of troubleshooting the issue told me that they could reload the latest image of my website to fix the problem.  The backup they have is about 24 hours ago and whatever I did in the time since the backup was done, will be gone – kapoot!

I told the support engineer not to restore. I will only use that as a last resort and would try to troubleshoot the problem myself.

I did a bulk deactivate on all my plugins and meticulously enable each plugins, starting from the most important plugins, and try the add plugins function, iteractively after each plugin activation. A tedious process indeed.  Lo and behold I found the offending plugin – MOJO Sliding Widget Panel Plugin. The moment I installed and activate the MOJO, it broke my “Add Plugin” functionality in my WordPress producing the same error above. I removed the offending plugins and proceeded to install the rest of the plugins. I am not sure why “MOJO” became the rogue as I have installed it for quite some time already before breaking the “Add Plugin”. My theory would be the changes in the back-end, an update maybe, that was installed recently by the Service Provider,  could not tolerate the “MOJO” in the “class-wp-plugin-install-list-table.php.  Of course, it was a stab in the dark as I don’t really know for sure. Have you seen such error or warning and how do you fix yours? Do comment and share your thoughts if you experienced the same problem.


Lucas M.

Full Error Message below:

“Warning: Attempt to assign property of non-object in /public_html/wp-admin/includes/plugin-install.php on line 192

Warning: uasort() expects parameter 1 to be array, null given in /public_html/wp-admin/includes/class-wp-plugin-install-list-table.php on line 218”