#318993 by stella, Patch for problems found in code review.
[project/filefield.git] / filefield_file.inc
CommitLineData
d2f124d5
DP
1<?php
2
3/**
4 * @file
5 * FileField hook_file callbacks.
6 */
7
8function filefield_file_references($file) {
9 $references = 0;
10 foreach(content_fields() as $field) {
11 if ($field['type'] != 'file') {
12 continue;
13 }
14 $references += field_file_references($file, $field);
15 }
16 return array('filefield' => $references);
17}
6f0f10d4
DP
18
19function filefield_file_delete($file) {
20 // foreach field... remove items referencing $file.
21}
7e784adc 22