diff options
author | Dries Buytaert <dries@buytaert.net> | 2001-05-16 20:54:37 +0000 |
---|---|---|
committer | Dries Buytaert <dries@buytaert.net> | 2001-05-16 20:54:37 +0000 |
commit | 6f02738cc2ca88d01d541b9b81cc7cf860980c33 (patch) | |
tree | 81ef242e0ae747e1715142dd370450bbed651ceb /modules/account.module | |
parent | 0b13183e097ae941db44a52b5ce5dc97faef99c2 (diff) | |
download | brdo-6f02738cc2ca88d01d541b9b81cc7cf860980c33.tar.gz brdo-6f02738cc2ca88d01d541b9b81cc7cf860980c33.tar.bz2 |
- Removed the "history"-field from the SQL table "users" and added
this information to the "users"-field in both nodes and comments.
This database/table change reduces the number of SQL queries and
makes Drupal scale better where a lot of voting/moderation takes
place. Last but not least it can be considered a new and better
foundation for future moderation metrics / algorithms. In other
words: it is plain better.
--> oops, all voting/moderation results will be lost!
--> requires database update, see "2.00-to-x.xx.sql"!
- Updated database/database.mysql
Diffstat (limited to 'modules/account.module')
-rw-r--r-- | modules/account.module | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/modules/account.module b/modules/account.module index 5f77c995b..28faf1fe3 100644 --- a/modules/account.module +++ b/modules/account.module @@ -140,8 +140,7 @@ function account_delete($name) { function account_edit_save($name, $edit) { foreach ($edit as $key=>$value) if ($key != "access") $query .= "$key = '". addslashes($value) ."', "; db_query("UPDATE users SET $query access = '' WHERE userid = '$name'"); - if ($edit[access]) foreach ($edit[access] as $key=>$value) user_set(user_load($name), "access", $value, 1); - + if ($edit[access]) foreach ($edit[access] as $key=>$value) db_query("UPDATE users SET access = '". field_set(user_load($name), "access", $value, 1) ."'"); watchdog("message", "account: modified user '$name'"); } |