Index: modules/openlayers_views/views/openlayers_views_style_map.inc
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/openlayers/modules/openlayers_views/views/openlayers_views_style_map.inc,v
retrieving revision 1.10
diff -u -p -r1.10 openlayers_views_style_map.inc
--- modules/openlayers_views/views/openlayers_views_style_map.inc	10 Jun 2009 04:58:02 -0000	1.10
+++ modules/openlayers_views/views/openlayers_views_style_map.inc	11 Jun 2009 15:46:04 -0000
@@ -199,7 +199,6 @@ class openlayers_views_style_map extends
    */
   function map_features($rows = array()) {  
     $features = array();    
-    $content_fields = content_fields();        
     $read_geo = $this->options['read_geo'];
             
     // Get list of fields in this view
@@ -275,9 +274,6 @@ class openlayers_views_style_map extends
   function query() {
     $read_geo = $this->options['read_geo'];
     
-    // Get all fields.
-    $content_fields = content_fields();
-    
     // Load data from Node Locations
     if ($read_geo['value'] == 'node_locations') {
       $table = $this->view->query->ensure_table('location');
@@ -286,6 +282,7 @@ class openlayers_views_style_map extends
     }
         
     if ($read_geo['value'] == 'geo') {                
+      $content_fields = content_fields();
       foreach ($content_fields as $content_field){
         if(in_array($content_field['field_name'],array_keys($read_geo['geo']))) {
           $content_table = $this->view->query->ensure_table('node_data_'.$content_field['field_name']);         
@@ -392,4 +389,4 @@ class openlayers_views_style_map extends
     
     return $output;
   }
-}
\ No newline at end of file
+}
