diff options
author | webchick <webchick@24967.no-reply.drupal.org> | 2011-04-24 01:40:28 -0700 |
---|---|---|
committer | webchick <webchick@24967.no-reply.drupal.org> | 2011-04-24 01:40:28 -0700 |
commit | 44a216f8fbf7211b023a0d301c107e501f0e7eaf (patch) | |
tree | 6f1b7f4310ba8d987724887798fd79492016e913 | |
parent | ef5ef9efc7a519f74f6bbdf8c87ba9bc16be5651 (diff) | |
download | brdo-44a216f8fbf7211b023a0d301c107e501f0e7eaf.tar.gz brdo-44a216f8fbf7211b023a0d301c107e501f0e7eaf.tar.bz2 |
Issue #817482 by Stevel, bfroehle: user_save() issues a warning when saving without changing mail attribute.
-rw-r--r-- | modules/user/user.module | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/modules/user/user.module b/modules/user/user.module index d33ddaa9b..358b4cec5 100644 --- a/modules/user/user.module +++ b/modules/user/user.module @@ -562,7 +562,9 @@ function user_save($account, $edit = array(), $category = 'account') { if (!isset($edit['created'])) { $edit['created'] = REQUEST_TIME; } - $edit['mail'] = trim($edit['mail']); + if (isset($edit['mail'])) { + $edit['mail'] = trim($edit['mail']); + } $success = drupal_write_record('users', $edit); if ($success === FALSE) { // On a failed INSERT some other existing user's uid may be returned. |