summaryrefslogtreecommitdiff
path: root/modules/image
diff options
context:
space:
mode:
authorAngie Byron <webchick@24967.no-reply.drupal.org>2010-01-13 06:26:49 +0000
committerAngie Byron <webchick@24967.no-reply.drupal.org>2010-01-13 06:26:49 +0000
commit83c97345e8eada544d7da4586e2c77db469ed5b1 (patch)
treea1f3be8ca91873c1da221d108470bbac8dc1bb0d /modules/image
parentc78283e81bb60fd6c4574ad65d2b854dca524a98 (diff)
downloadbrdo-83c97345e8eada544d7da4586e2c77db469ed5b1.tar.gz
brdo-83c97345e8eada544d7da4586e2c77db469ed5b1.tar.bz2
#525622 by Frando, yched, et al: Add entity hook callbacks so that 'as link' formatters have a generic way to build the url of an 'entity'.
Diffstat (limited to 'modules/image')
-rw-r--r--modules/image/image.field.inc3
1 files changed, 1 insertions, 2 deletions
diff --git a/modules/image/image.field.inc b/modules/image/image.field.inc
index f7bb499de..1b4a96852 100644
--- a/modules/image/image.field.inc
+++ b/modules/image/image.field.inc
@@ -463,8 +463,7 @@ function image_field_formatter_view($obj_type, $object, $field, $instance, $lang
// Check if the formatter involves a link.
if (strpos($display['type'], 'image_link_content') === 0) {
- list($id) = entity_extract_ids($obj_type, $object);
- $path = $obj_type . '/' . $id;
+ $path = entity_path($obj_type, $object);
}
elseif (strpos($display['type'], 'image_link_file') === 0) {
$link_file = TRUE;