summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--filefield.module13
1 files changed, 13 insertions, 0 deletions
diff --git a/filefield.module b/filefield.module
index fa26738..b7b230a 100644
--- a/filefield.module
+++ b/filefield.module
@@ -357,6 +357,19 @@ function filefield_content_is_empty($item, $field) {
}
/**
+ * Implementation of CCK's hook_content_diff_values().
+ */
+function filefield_content_diff_values($node, $field, $items) {
+ $return = array();
+ foreach ($items as $item) {
+ if (is_array($item) && !empty($item['filepath'])) {
+ $return[] = $item['filepath'];
+ }
+ }
+ return $return;
+}
+
+/**
* Implementation of CCK's hook_default_value().
*
* Note this is a widget-level hook, so it does not affect ImageField or other