def location_gmap(context, location):
    """Display a link to Google maps iff we are using WagtailGMaps"""
    gmapq = None
    if getattr(MapFieldPanel, "UsingWagtailGMaps", False):
        gmapq = location
    return {'gmapq': gmapq}
Display a link to Google maps iff we are using WagtailGMaps