Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

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

Credit goes to jean-christophe zulian
  • Loading branch information...
commit 77fcfa7395622c8000f2b9f42cb5f7c98b97e7e7 1 parent d3e2dfa
@stronk7 stronk7 authored
Showing with 1 addition and 3 deletions.
  1. +1 −3 backup/restorelib.php
View
4 backup/restorelib.php
@@ -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)) {
Please sign in to comment.
Something went wrong with that request. Please try again.