Commit fc99c57d authored by Steven Wittens's avatar Steven Wittens

#6732: fixing bug 'once anonymous always anoymous' (nodes).

parent 6a380525
......@@ -460,7 +460,7 @@ function node_save($node) {
$v[] = $value;
}
}
// Update the node in the database:
db_query("UPDATE {node} SET ". implode(', ', $q) ." WHERE nid = '$node->nid'", $v);
......@@ -1059,7 +1059,7 @@ function node_validate($node) {
}
// Validate the "authored by" field.
if (empty($node->name) || empty($node->uid)){
if (empty($node->name)) {
// The use of empty() is mandatory in the context of usernames
// as the empty string denotes the anonymous user. In case we
// are dealing with an anomymous user we set the user ID to 0.
......
......@@ -460,7 +460,7 @@ function node_save($node) {
$v[] = $value;
}
}
// Update the node in the database:
db_query("UPDATE {node} SET ". implode(', ', $q) ." WHERE nid = '$node->nid'", $v);
......@@ -1059,7 +1059,7 @@ function node_validate($node) {
}
// Validate the "authored by" field.
if (empty($node->name) || empty($node->uid)){
if (empty($node->name)) {
// The use of empty() is mandatory in the context of usernames
// as the empty string denotes the anonymous user. In case we
// are dealing with an anomymous user we set the user ID to 0.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment