Title: Issue on HTTP
Last modified: July 31, 2023

---

# Issue on HTTP

 *  Resolved [Alfinator39](https://wordpress.org/support/users/alfinator39/)
 * (@alfinator39)
 * [2 years, 10 months ago](https://wordpress.org/support/topic/issue-on-http/)
 * Hello we have a big issue when we work offline or on HTTP
 * The main problem is that your plugin always checks the last version of siteorigin-
   installer (which is not great)
 * and the request always offline or HTTP returns error
 * And because is an error the value instead of ARRAY is FALSE. But your code expects
   an array. The solution is straightforward
 * In siteorign-panels and so-widgets-bundle in file github-plugin-updater.php
 * in this code
 * public function check_for_update( $transient ) {
   $all_headers = $this->get_plugin_headers();
   $plugin_path = $this->get_plugin_path();
 * if ( version_compare( _SITEORIGIN\_INSTALLER\_VERSION_, $all_headers[‘Version’],‘
   <‘ ) ) {
   // There is a newer version available on Github$update = new stdClass();
   $update->slug = $plugin_path;$update->new_version = $all_headers[‘Version’];$
   update->url = $all_headers[‘PluginURI’];$update->package = ‘[https://github.com/siteorigin/siteorigin-installer/archive/&#8217](https://github.com/siteorigin/siteorigin-installer/archive/&#8217);.
   self::_UPDATES\_BRANCH _. ‘.zip’;
 * $transient->response[ $plugin_path ] = $update;
   }
 * return $transient;
   }
 * **add verification that $all_headers are not false**
 * public function check_for_update( $transient ) {
   $all_headers = $this->get_plugin_headers();
   $plugin_path = $this->get_plugin_path();
 * if ( $all_headers && version_compare( _SITEORIGIN\_INSTALLER\_VERSION_, $all_headers[‘
   Version’], ‘<‘ ) ) {
   // There is a newer version available on Github$update =
   new stdClass();$update->slug = $plugin_path;$update->new_version = $all_headers[‘
   Version’];$update->url = $all_headers[‘PluginURI’];$update->package = ‘[https://github.com/siteorigin/siteorigin-installer/archive/&#8217](https://github.com/siteorigin/siteorigin-installer/archive/&#8217);.
   self::_UPDATES\_BRANCH _. ‘.zip’;
 * $transient->response[ $plugin_path ] = $update;
   }
 * return $transient;
   }
 * **OR verify that $all_headers[‘Version’]** **is set** because if is not set there
   is an error notice.
 * Thank you

Viewing 2 replies - 1 through 2 (of 2 total)

 *  Plugin Support [Andrew Misplon](https://wordpress.org/support/users/misplon/)
 * (@misplon)
 * [2 years, 10 months ago](https://wordpress.org/support/topic/issue-on-http/#post-16936357)
 * Hi, thanks for your detailed feedback; it’s most appreciated. I’ve asked Alex
   at SiteOrigin to reply with a solution as soon as he’s able to.
 * Kind regards
 * Andrew
 *  Plugin Contributor [alexgso](https://wordpress.org/support/users/alexgso/)
 * (@alexgso)
 * [2 years, 10 months ago](https://wordpress.org/support/topic/issue-on-http/#post-16938245)
 * Hi,
 * Thank you for the report. I’ve run a few tests and come up with a fix to prevent
   this. This fix will be included in a future update.
 * Kind regards,
   Alex

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘Issue on HTTP’ is closed to new replies.

 * ![](https://ps.w.org/siteorigin-panels/assets/icon.svg?rev=2556869)
 * [Page Builder by SiteOrigin](https://wordpress.org/plugins/siteorigin-panels/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/siteorigin-panels/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/siteorigin-panels/)
 * [Active Topics](https://wordpress.org/support/plugin/siteorigin-panels/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/siteorigin-panels/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/siteorigin-panels/reviews/)

 * 2 replies
 * 3 participants
 * Last reply from: [alexgso](https://wordpress.org/support/users/alexgso/)
 * Last activity: [2 years, 10 months ago](https://wordpress.org/support/topic/issue-on-http/#post-16938245)
 * Status: resolved