--- CVS\excerpt\excerpt.module	2005-03-08 12:44:32.106056000 -0800
+++ Geary\excerpt\excerpt.module	2005-03-08 12:56:50.888372800 -0800
@@ -17,20 +17,29 @@
       break;
     case 'form post':
       if (variable_get("excerpt_$node->type", 1)) {
-        $output = form_textarea(t('Excerpt'), 'teaser', $node->teaser, 60, 10, t('Enter an excerpt for this item. It will be shown on listing pages along with a <em>read more</em> link which leads to the full view. Leave empty to auto-generate one from the body.'));
+        $teaser = ($node->teaser != node_teaser($node->body) ? $node->teaser : '');
+        $output = form_textarea(t('Excerpt'), 'teaser', $teaser, 60, 10, t('Enter an excerpt for this item. It will be shown on listing pages along with a <em>read more</em> link which leads to the full view. Leave empty to automatically generate an excerpt from the body, or enter a space character to have no excerpt.'));
       }
       break;
     case 'validate':
-      if (trim($node->teaser) == '') {
+      if ($node->teaser == '') {
         $node->teaser = node_teaser($node->body);
       }
       break;
     case 'view':
-      $node->readmore = $node->teaser !== $node->body;
+      // node_prepare() is called before this code, so at this point either the body or the
+      // teaser has been run through check_output. We convert the other one before comparing.
+      // Question: Does readmore need to be calculated at all when $main is false? If not,
+      // this could be simplified to:
+      // $node->readmore = $main && check_output($node->teaser, $node->format) !== $node->body;
+      if( $main )
+        $node->readmore = check_output($node->teaser, $node->format) !== $node->body;
+      else
+        $node->readmore = $node->teaser !== check_output($node->body, $node->format);
       break;
   }
 
   return $output;
 }
 
-?>
\ No newline at end of file
+?>
