leaflet_googlemaps.js is loaded before drupal_leaflet.js so Drupal.leaflet is undefided causing an error. The solution is altering the rendering order of the js library script tag. In leaflet_googlemaps.module change line 96 to this one:

drupal_add_js(drupal_get_path('module', 'leaflet_googlemaps') . '/leaflet_googlemaps.js', array('weight' => 10));

Comments

jherencia’s picture

Assigned: Unassigned » jherencia
jherencia’s picture

Status: Active » Fixed

I haven't reproduced the problem, but in any case increasing the weight of these libraries does not break anything.

Thank you!

http://drupalcode.org/project/leaflet_googlemaps.git/commit/b27d843545b2...

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.