Title: Version 1.0.3 throws an error message
Last modified: August 22, 2016

---

# Version 1.0.3 throws an error message

 *  Resolved [wneufeldjvi](https://wordpress.org/support/users/wneufeldjvi/)
 * (@wneufeldjvi)
 * [11 years, 3 months ago](https://wordpress.org/support/topic/version-103-throws-an-error-message/)
 * Hi,
 * The latest version was automatically updated on our sites last night and this
   morning, and now our sites are displaying this error in Chrome, IE, and Firefox,
   at the top of the pages:
 * Warning: Invalid argument supplied for foreach() in /home4/jviation/public_html/
   wordpress-jv1/wp-content/plugins/google-maps-builder/public/class-wordpress-google-
   maps.php on line 537
 * Thank you.
 * [https://wordpress.org/plugins/google-maps-builder/](https://wordpress.org/plugins/google-maps-builder/)

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

 *  Plugin Author [Matt Cromwell](https://wordpress.org/support/users/webdevmattcrom/)
 * (@webdevmattcrom)
 * [11 years, 3 months ago](https://wordpress.org/support/topic/version-103-throws-an-error-message/#post-5696914)
 * Can you provide a link to your site so I can see what’s going on?
 *  Thread Starter [wneufeldjvi](https://wordpress.org/support/users/wneufeldjvi/)
 * (@wneufeldjvi)
 * [11 years, 3 months ago](https://wordpress.org/support/topic/version-103-throws-an-error-message/#post-5696918)
 * [http://jviation.com/about-us/salt-lake-city-office-directions/](http://jviation.com/about-us/salt-lake-city-office-directions/)
 *  Plugin Author [Matt Cromwell](https://wordpress.org/support/users/webdevmattcrom/)
 * (@webdevmattcrom)
 * [11 years, 3 months ago](https://wordpress.org/support/topic/version-103-throws-an-error-message/#post-5696933)
 * Do you have any plugins that deal with Javascript or CSS minification? Or plugins
   that try to manage the scripts of other plugins (like Plugin Organizer)?
 *  [theo70a_](https://wordpress.org/support/users/theo70a_/)
 * (@theo70a_)
 * [11 years, 3 months ago](https://wordpress.org/support/topic/version-103-throws-an-error-message/#post-5696954)
 * Matt, I just turned off ALL plugins except yours on the jviation.com site. Still
   shows error at top of page:
    Warning: Invalid argument supplied for foreach()
 *  Plugin Author [Matt Cromwell](https://wordpress.org/support/users/webdevmattcrom/)
 * (@webdevmattcrom)
 * [11 years, 3 months ago](https://wordpress.org/support/topic/version-103-throws-an-error-message/#post-5696961)
 * OK, can you email me that theme at support at wordimpress.com
 *  Thread Starter [wneufeldjvi](https://wordpress.org/support/users/wneufeldjvi/)
 * (@wneufeldjvi)
 * [11 years, 3 months ago](https://wordpress.org/support/topic/version-103-throws-an-error-message/#post-5697074)
 * Matt, Ted sent you the theme a couple of hours ago. We tried five other themes
   on our dev site, and we get the same error. Themes are:
    Enigma, Orangi, Formation,
   Virtue, and Albar. These are unmodified themes directly from WordPress. Thanks.
 *  [theo70a_](https://wordpress.org/support/users/theo70a_/)
 * (@theo70a_)
 * [11 years, 3 months ago](https://wordpress.org/support/topic/version-103-throws-an-error-message/#post-5697169)
 * I rolled Google Maps Builder back to 1.0.2 on the site for now. That version 
   appears to be working and is not throwing an error. I also have all of the plugins
   enabled again, including Plugin Organizer 5.7.6.
    Thanks.
 *  [barryhyde](https://wordpress.org/support/users/barryhyde/)
 * (@barryhyde)
 * [11 years, 3 months ago](https://wordpress.org/support/topic/version-103-throws-an-error-message/#post-5697228)
 * I see the same problem.
 * The latest version of the plugin causes this error **sometimes** on a wordpress
   site.
 * “Warning: Invalid argument supplied for foreach() in /websites/la/laregotool.
   com.au/r764abq/wp-content/plugins/google-maps-builder/public/class-wordpress-
   google-maps.php on line 537”
 * This did not occur on the previous version and started as soon as the new version
   was activated.
 * Any fix available yet?
 * Using wordpress 4.1.
 * thanks
    Barry
 *  Plugin Author [Devin Walker](https://wordpress.org/support/users/dlocc/)
 * (@dlocc)
 * [11 years, 3 months ago](https://wordpress.org/support/topic/version-103-throws-an-error-message/#post-5697248)
 * Hey the fix is coming in the next release but for now you can add:
 *     ```
       if ( ! isset( $wp_scripts->registered ) ) {
       			return false;
       		}
       ```
   
 * above line 537 in public/class-wordpress-google-maps.php to fix the issue
 *  [bgrog22](https://wordpress.org/support/users/bgrog22/)
 * (@bgrog22)
 * [11 years, 3 months ago](https://wordpress.org/support/topic/version-103-throws-an-error-message/#post-5697341)
 * Hi,
 * I just updated to the new Google Maps plugin and was getting this same error.
   I added the “fix” to public/class-wordpress-google-maps.php saved it and now 
   am getting this error
 * “Parse error: syntax error, unexpected ‘public’ (T_PUBLIC) in /home/rebgro4/beccagrogan.
   com/wp-content/plugins/google-maps-builder/public/class-wordpress-google-maps.
   php on line 320”
 * I can’t even log in to my WordPress to delete the plugin or make changes. It 
   just shows this and nothing else.
 *  [mirchonka](https://wordpress.org/support/users/mirchonka/)
 * (@mirchonka)
 * [11 years, 1 month ago](https://wordpress.org/support/topic/version-103-throws-an-error-message/#post-5697386)
 * I tried to install this plugin now and also got an error:
 * Fatal error: Call to undefined function cmb_get_option() in C:\xampp\apps\wordpress\
   htdocs\wp-content\plugins\google-maps-builder\admin\class-wordpress-google-maps-
   settings.php on line 422
 * I cannot even uninstall the plugin from wordpress or log in to my site.
    What’s
   happening and what should I do?
 *  [WPyogi](https://wordpress.org/support/users/wpyogi/)
 * (@wpyogi)
 * [11 years, 1 month ago](https://wordpress.org/support/topic/version-103-throws-an-error-message/#post-5697387)
 * You can remove that plugin manually – **using FTP or Cpanel**, find it here and
   delete it:
 *     ```
       wp-content
           plugins
               google-maps-builder - DELETE THIS FOLDER
       ```
   
 *  Plugin Author [Devin Walker](https://wordpress.org/support/users/dlocc/)
 * (@dlocc)
 * [11 years, 1 month ago](https://wordpress.org/support/topic/version-103-throws-an-error-message/#post-5697388)
 * Thanks WP Yogi – we’ll hotfix this today. Never want any Fatal errors.!
 *  [Nashy](https://wordpress.org/support/users/nashy/)
 * (@nashy)
 * [11 years, 1 month ago](https://wordpress.org/support/topic/version-103-throws-an-error-message/#post-5697392)
 * So even with the above “fix” I still get the error.
 * > Warning: Invalid argument supplied for foreach() in _[site]_/wp-content/plugins/
   > google-maps-builder/public/class-wordpress-google-maps.php on line 537
 *     ```
       public function check_for_multiple_google_maps_api_calls() {
   
       		global $wp_scripts;
   
       		$multiple_google_maps_api = false;
   
       if ( ! isset( $wp_scripts->registered ) ) {
       			return false;
       		}
   
       		//loop through registered scripts
       		foreach ( $wp_scripts->registered as $registered_script ) {
       ```
   
 * Would appreciate some help, or at least a time frame of when a fix will be available.
   I can’t run a site with a horrid looking error message on it.
 * Thanks for any help.

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

The topic ‘Version 1.0.3 throws an error message’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/google-maps-builder_f9f9f9.svg)
 * [Maps Builder - Google Maps Plugin](https://wordpress.org/plugins/google-maps-builder/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/google-maps-builder/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/google-maps-builder/)
 * [Active Topics](https://wordpress.org/support/plugin/google-maps-builder/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/google-maps-builder/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/google-maps-builder/reviews/)

 * 14 replies
 * 9 participants
 * Last reply from: [Nashy](https://wordpress.org/support/users/nashy/)
 * Last activity: [11 years, 1 month ago](https://wordpress.org/support/topic/version-103-throws-an-error-message/#post-5697392)
 * Status: resolved