Index: ParserIcalFeedsParser.inc
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/parser_ical/includes/ParserIcalFeedsParser.inc,v
retrieving revision 1.1
diff -u -r1.1 ParserIcalFeedsParser.inc
--- ParserIcalFeedsParser.inc	19 Jan 2010 11:55:42 -0000	1.1
+++ ParserIcalFeedsParser.inc	17 Mar 2010 20:19:37 -0000
@@ -28,17 +28,25 @@
       $this->start->removeGranularity('second');
       $this->end = clone $this->start;
    }
-
-    if (array_key_exists('RRULE', $feed_element) && !empty($feed_element['RRULE']) && module_exists('date_repeat')) {
-      include_once('./'. drupal_get_path('module', 'date_repeat') .'/date_repeat_calc.inc');
-      include_once('./'. drupal_get_path('module', 'date') .'/date_repeat.inc');
+    if (array_key_exists('RRULE', $feed_element) && !empty($feed_element['RRULE'])) {
       // Explode the RRULE into parts so we can analyze it.
       $rrule = $feed_element['RRULE']['DATA'] . (!empty($feed_element['EXDATE']) ? "/n". $feed_element['EXDATE'] : "");
       // In current API the first variable, $field, is unused--may change?
@@ -91,10 +99,14 @@
     if (empty($this->repeat_vals)) {
       return;
     }
-    $field = content_fields($field_name);
-    $node_field = $node->{$field_name}[0];
-    $values = date_repeat_build_dates(NULL, $this->repeat_vals, $field, $node_field);
-    $node->$field_name = $values;
+    if (module_exists('date') && module_exists('date_repeat')) {
+      include_once('./'. drupal_get_path('module', 'date_repeat') .'/date_repeat_calc.inc');
+      include_once('./'. drupal_get_path('module', 'date') .'/date_repeat.inc');
+      $field = content_fields($field_name);
+      $node_field = $node->{$field_name}[0];
+      $values = date_repeat_build_dates(NULL, $this->repeat_vals, $field, $node_field);
+      $node->$field_name = $values;
+    }
   }
 }
 
