Permalink
Browse files

MDL-21370 restore - avoid adding slashes twice to user info

Credit goes to jean-christophe zulian
  • Loading branch information...
1 parent d3e2dfa commit 77fcfa7395622c8000f2b9f42cb5f7c98b97e7e7 @stronk7 stronk7 committed Jan 18, 2010
Showing with 1 addition and 3 deletions.
  1. +1 −3 backup/restorelib.php
View
@@ -2809,7 +2809,7 @@ function restore_create_users($restore,$xml_file) {
$user = $useridsdbrec->info;
foreach (array_keys(get_object_vars($user)) as $field) {
if (!is_array($user->$field)) {
- $user->$field = backup_todb($user->$field);
+ $user->$field = backup_todb($user->$field, false);
if (is_null($user->$field)) {
$user->$field = '';
}
@@ -2909,8 +2909,6 @@ function restore_create_users($restore,$xml_file) {
if ($create_user) {
//Unset the id because it's going to be inserted with a new one
unset ($user->id);
- // relink the descriptions
- $user->description = stripslashes($user->description);
/// Disable pictures based on global setting or existing empty value (old backups can contain wrong empties)
if (!empty($CFG->disableuserimages) || empty($user->picture)) {

0 comments on commit 77fcfa7

Please sign in to comment.