New Plugin & Theme updater integrations for Software Licensing

A short time ago, version 3.5.17 of our Software Licensing extension was released. With it, our sample plugin and theme were updated to include changes to EDD_SL_Plugin_Updater (version 1.6.13) and EDD_Theme_Updater_Admin classes, which changed the sslverify attribute to true. It had previously been intentionally set to false, to mitigate a consistent stream of support requests and customer issues related to hosting environments not supporting newer TLS protocols.

At this time, we’ve determined that it’s time to move forward and set the sslverify to true by default, and allow plugin and theme developers to use a filter to disable it if they choose to within their integration. The filter added is edd_sl_api_request_verify_ssl, and disabling it is as simple as the following line of code:

add_filter( 'edd_sl_api_request_verify_ssl', '__return_false' );

We’ve updated our documentation as well to reflect this new filter in the Important Notes section:

15 responses... add one

Hi,
Do I have to use ‘item_id’ or ‘item_name’?
Because in the Updater implementation for WordPress Plugins there is ‘item_id’, but in the sample plugin I have downloaded there is ‘item_name’. I’m using ‘item_name’ in my plugin, and it’s the first time I see ‘item_id’.

You can use either though “item_id” is better and more reliable. We’re in the process of updating all documentation and examples to use item_id as well.

What else needs to be changed besides using the new updater class? When I swap out the new EDD SL Updater class from the previous version, there is always a notice below my plugins saying that there is a new version available but that automatic update is not available for this plugin. So, I’m reverting back to the previous EDD SL Updater class for now.

All you need to do is replace the updater class in your plugin with the new version.

With the new version, the update cache may need to be refreshed before the update notification will be displayed.

It also gives this notice with the new version:
PHP Notice: Trying to get property of non-object in C:\xampp7\htdocs\wordpress-dev\wp-admin\includes\update.php on line 364

That notice shows up on admin plugins page as soon as I replaced the previous EDD SL Updater with the new one. Debug is on, and going to debug.log, in my dev environment, as well as Query Monitor.

Here is the complete notice with stack trace (repeated several times per page load):

[25-Jul-2017 16:34:14 UTC] PHP Notice: Trying to get property of non-object in C:\xampp7\htdocs\wordpress-dev\wp-admin\includes\update.php on line 364

[25-Jul-2017 16:34:14 UTC] PHP Stack trace:

[25-Jul-2017 16:34:14 UTC] PHP 1. {main}() C:\xampp7\htdocs\wordpress-dev\wp-admin\plugins.php:0

[25-Jul-2017 16:34:14 UTC] PHP 2. WP_List_Table->display() C:\xampp7\htdocs\wordpress-dev\wp-admin\plugins.php:547

[25-Jul-2017 16:34:14 UTC] PHP 3. WP_List_Table->display_rows_or_placeholder() C:\xampp7\htdocs\wordpress-dev\wp-admin\includes\class-wp-list-table.php:1141

[25-Jul-2017 16:34:14 UTC] PHP 4. WP_Plugins_List_Table->display_rows() C:\xampp7\htdocs\wordpress-dev\wp-admin\includes\class-wp-list-table.php:1213

[25-Jul-2017 16:34:14 UTC] PHP 5. WP_Plugins_List_Table->single_row() C:\xampp7\htdocs\wordpress-dev\wp-admin\includes\class-wp-plugins-list-table.php:536

[25-Jul-2017 16:34:14 UTC] PHP 6. do_action() C:\xampp7\htdocs\wordpress-dev\wp-admin\includes\class-wp-plugins-list-table.php:865

[25-Jul-2017 16:34:14 UTC] PHP 7. WP_Hook->do_action() C:\xampp7\htdocs\wordpress-dev\wp-includes\plugin.php:453

[25-Jul-2017 16:34:14 UTC] PHP 8. WP_Hook->apply_filters() C:\xampp7\htdocs\wordpress-dev\wp-includes\class-wp-hook.php:323

[25-Jul-2017 16:34:14 UTC] PHP 9. wp_plugin_update_row() C:\xampp7\htdocs\wordpress-dev\wp-includes\class-wp-hook.php:300

The below every plugin on the page that is active and uses EDD SL, it shows this (plugin name is correct for each plugin, but they all say the same thing):

There is a new version of WooCommerce User Role Minimums available. View version details. Automatic update is unavailable for this plugin.

None of the plugins actually have any updates available. This was also confirmed by another customer of mine who I sent a copy for testing with the new EDD SL Updater. Same notices, and same message below all plugins using the updater, even those that are not from me.

I came here same for the notice fix. I managed to fix it up by commented out line that was causing it:

$_transient_data->response[ $this->name ][ ‘slug’ ] = $this->slug;

Do you know why the notice happened with that line?

It seems that anyone from my customers that updated plugin that included new updater are having problem updating plugin to the new version, and this is kinda killing my support.

Can you confirm this is correct?

Also, even with the improved version, on one site i have old version of a plugin, and after removing “_site_transient_update_plugins” option, I am not getting new plugin version update. Can you confirm its only my side?

Leave a Reply

Your email address will not be published. Required fields are marked *