Index: /Users/bevan/Sites/jcause/sites/default/modules/contrib-5/imagecache/imagecache.module
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/imagecache/imagecache.module,v
retrieving revision 1.19.2.28
diff -u -r1.19.2.28 imagecache.module
--- imagecache.module	16 Jun 2007 17:22:41 -0000	1.19.2.28
+++ imagecache.module	15 Oct 2007 08:38:47 -0000
@@ -247,7 +247,7 @@
  * Implementation of hook_field_formatter().
  */
 function imagecache_field_formatter($field, $item, $formatter) {
-  if (!isset($item['fid'])) {
+  if (empty($item['fid'])) {
     return '';
   }
   // Views does not load the file for us, while CCK display fields does.
@@ -730,7 +730,7 @@
   if (preg_match('/_linked$/', $formatter)) {
     $formatter = preg_replace('/_linked$/', '', $formatter);
     $image = theme('imagecache', $formatter, $item['filepath'], $item['alt'], $item['title']);
-    $output = l($image, 'node/'. $item['nid'], array(), NULL, NULL, FALSE, TRUE);
+    $output = l($image, 'node/'. $item['nid'], array('class' => 'image imagecache'), NULL, NULL, FALSE, TRUE);
   }
   else {
     $output = theme('imagecache', $formatter, $item['filepath'], $item['alt'], $item['title']);
@@ -738,7 +738,7 @@
   return $output;
 }
 
-function theme_imagecache($namespace, $path, $alt = '', $title = '', $attributes = NULL) {
+function theme_imagecache($namespace, $path, $alt = '', $title = '', $attributes = array('class' => 'image imagecache')) {
   $attributes = drupal_attributes($attributes);
   $imagecache_path = file_create_url(file_directory_path() .'/imagecache/'. $namespace .'/'. $path);
   return '<img src="'. $imagecache_path .'" alt="'. check_plain($alt) .'" title="'. check_plain($title) .'" '. $attributes .' />';
