--- date_views.4.7.x-1.x-dev.inc	2007-02-24 08:59:05.000000000 -0600
+++ date_views.inc	2007-03-02 13:20:15.000000000 -0600
@@ -88,7 +88,7 @@ function date_views_filters($field) {
           'value' => date_views_handler_filter_date_value_form($field),
           'option' => 'string',
           'handler' => $handler,
-          'type' => 'DATE',
+          'type' => 'to|DATE',
           'extra' => array('field' => $field),
           'help' => t('This filter allows events to be filtered by their date. Enter dates in the format: %format. Enter \'now\' to use the current time. You may enter a delta (in seconds) to the option that will be added to the time; this is most useful when combined with now. If you have the jscalendar module from jstools installed, you can use a popup date picker here.', array('%format' => $format)),
           ),
@@ -97,7 +97,7 @@ function date_views_filters($field) {
           'operator' => $operator,
           'handler' => $handler,
           'option' => 'string',
-          'type' => 'YEAR',
+          'type' => 'to|YEAR',
           'extra' => array('field' => $field),
           'help' => t('Filter by year. Enter \'now\' to use the current year.  You may enter a delta (in seconds) to the option that will be added to the time; this is most useful when combined with now. '),
           ),
@@ -108,7 +108,7 @@ function date_views_filters($field) {
           'list-type' => 'select',
           'handler' => $handler,
           'option' => 'string',
-          'type' => 'MONTH',
+          'type' => 'to|MONTH',
           'extra' => array('field' => $field),
           'help' => t('Filter by month. Enter \'now\' to use the current month.  You may enter a delta (in seconds) to the option that will be added to the time; this is most useful when combined with now. '),
           ),
@@ -119,7 +119,7 @@ function date_views_filters($field) {
           'list-type' => 'select',
           'handler' => $handler,
           'option' => 'string',
-          'type' => 'DAY',
+          'type' => 'to|DAY',
           'extra' => array('field' => $field),
           'help' => t('Filter by day. Enter \'now\' to use the current day.  You may enter a delta (in seconds) to the option that will be added to the time; this is most useful when combined with now. '),
           ),
@@ -144,13 +144,12 @@ function date_views_filter_handler($op, 
   $totype = $filterinfo['type'];
   $type = substr($totype, 0, 3) == 'to|' ? substr($totype, 3) : $totype;
   if ($totype == $type) {
-    $value = $filter['value'];
     $column = 'value';
   }
   else {
-    $value = $filter['value2'];
     $column = 'value2';
   }
+  $value = $filter['value'];
 
   include_once(drupal_get_path('module', 'date_api') .'/date.inc');
 
@@ -168,7 +167,7 @@ function date_views_filter_handler($op, 
   // the offset we really want, and add back the right offset.
   // This will be necessary any time the server timezone does not match the site or date zone
   // because the server is going to adjust the value of NOW() for the server timezone.
-  switch ($filterinfo['type']) {
+  switch ($type) {
     case ('DATE'):
       $date = $value == 'now' ? date_sql('NOW', 'NOW()', $field_type, $offset) : "'". str_replace('T', ' ', date_custom2iso($value, $formats['input']['text'])) ."'";
       break;
