Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

mnet: backup_general_info() now indicates whether it includes MNET_RE…

…MOTEUSERS
  • Loading branch information...
commit c0543ba1f7fb87039d6f0e8586fa859768505419 1 parent 818c1b0
martinlanghoff authored
Showing with 9 additions and 0 deletions.
  1. +9 −0 backup/backuplib.php
View
9 backup/backuplib.php
@@ -450,6 +450,15 @@ function backup_general_info ($bf,$preferences) {
} else {
$zipmethod = 'internal';
}
+ //Indicate if it includes external MNET users
+ $sql = "SELECT b.old_id
+ FROM {$CFG->prefix}backup_ids b
+ JOIN {$CFG->prefix}user u ON b.old_id=u.id
+ WHERE b.backup_code = '$preferences->backup_unique_code'
+ AND b.table_name = 'user' AND u.mnethostid != '{$CFG->mnet_localhost_id}'";
+ if (record_exists_sql($sql)) {
+ fwrite ($bf,full_tag("MNET_REMOTEUSERS",2,false,'true'));
+ }
fwrite ($bf,full_tag("ZIP_METHOD",2,false,$zipmethod));
//Te includes tag
fwrite ($bf,start_tag("DETAILS",2,true));
Please sign in to comment.
Something went wrong with that request. Please try again.