summaryrefslogtreecommitdiff
path: root/modules/node
diff options
context:
space:
mode:
authorDries Buytaert <dries@buytaert.net>2010-06-29 00:57:19 +0000
committerDries Buytaert <dries@buytaert.net>2010-06-29 00:57:19 +0000
commitb6c0d1ab208af3cd16316324f54d2e10875b5286 (patch)
treef569d6bf46c680a867e5c838b91be00659a32265 /modules/node
parentcbfdd2e9c7bc67f374ecb434369111d630399fea (diff)
downloadbrdo-b6c0d1ab208af3cd16316324f54d2e10875b5286.tar.gz
brdo-b6c0d1ab208af3cd16316324f54d2e10875b5286.tar.bz2
- Patch #831914 by Dave Reid: removed redundant/duplicate [node:uid], [comment:uid], and [file:uid] tokens.
Diffstat (limited to 'modules/node')
-rw-r--r--modules/node/node.test2
-rw-r--r--modules/node/node.tokens.inc8
2 files changed, 1 insertions, 9 deletions
diff --git a/modules/node/node.test b/modules/node/node.test
index 629509c7a..7369b8699 100644
--- a/modules/node/node.test
+++ b/modules/node/node.test
@@ -1730,7 +1730,6 @@ class NodeTokenReplaceTestCase extends DrupalWebTestCase {
$tests['[node:nid]'] = $node->nid;
$tests['[node:vid]'] = $node->vid;
$tests['[node:tnid]'] = $node->tnid;
- $tests['[node:uid]'] = $node->uid;
$tests['[node:type]'] = 'article';
$tests['[node:type-name]'] = 'Article';
$tests['[node:title]'] = check_plain($node->title);
@@ -1739,6 +1738,7 @@ class NodeTokenReplaceTestCase extends DrupalWebTestCase {
$tests['[node:language]'] = check_plain($node->language);
$tests['[node:url]'] = url('node/' . $node->nid, $url_options);
$tests['[node:edit-url]'] = url('node/' . $node->nid . '/edit', $url_options);
+ $tests['[node:author:uid]'] = $node->uid;
$tests['[node:author:name]'] = check_plain($account->name);
$tests['[node:created:since]'] = format_interval(REQUEST_TIME - $node->created, 2, $language->language);
$tests['[node:changed:since]'] = format_interval(REQUEST_TIME - $node->changed, 2, $language->language);
diff --git a/modules/node/node.tokens.inc b/modules/node/node.tokens.inc
index c28e5347e..be064ab29 100644
--- a/modules/node/node.tokens.inc
+++ b/modules/node/node.tokens.inc
@@ -31,10 +31,6 @@ function node_token_info() {
'name' => t("Translation set ID"),
'description' => t("The unique ID of the original-language version of this node, if one exists."),
);
- $node['uid'] = array(
- 'name' => t("User ID"),
- 'description' => t("The unique ID of the user who posted the node."),
- );
$node['type'] = array(
'name' => t("Content type"),
'description' => t("The type of the node."),
@@ -125,10 +121,6 @@ function node_tokens($type, $tokens, array $data = array(), array $options = arr
$replacements[$original] = $node->tnid;
break;
- case 'uid':
- $replacements[$original] = $node->uid;
- break;
-
case 'type':
$replacements[$original] = $sanitize ? check_plain($node->type) : $node->type;
break;