Changes 3 and 4 of the google sheet
This commit is contained in:
@@ -6,7 +6,7 @@
|
||||
*
|
||||
* Exports the database and copies the files to an tar archive o several if the max filesize is reached.
|
||||
*/
|
||||
|
||||
|
||||
/**
|
||||
* Class MultipleFilesBackup
|
||||
* create a backup of this workspace
|
||||
@@ -135,7 +135,7 @@
|
||||
if (empty( $metaFiles )) {
|
||||
$metaFiles = glob( $tempDirectory . "/*.txt" );
|
||||
if (! empty( $metaFiles )) {
|
||||
return workspaceTools::restoreLegacy( $tempDirectory );
|
||||
return WorkspaceTools::restoreLegacy( $tempDirectory );
|
||||
} else {
|
||||
throw new Exception( "No metadata found in backup" );
|
||||
}
|
||||
@@ -170,7 +170,7 @@
|
||||
} else {
|
||||
CLI::logging( "> Restoring " . CLI::info( $backupWorkspace ) . " to " . CLI::info( $workspaceName ) . "\n" );
|
||||
}
|
||||
$workspace = new workspaceTools( $workspaceName );
|
||||
$workspace = new WorkspaceTools( $workspaceName );
|
||||
if ($workspace->workspaceExists()) {
|
||||
if ($overwrite) {
|
||||
CLI::logging( CLI::warning( "> Workspace $workspaceName already exist, overwriting!" ) . "\n" );
|
||||
@@ -194,7 +194,7 @@
|
||||
CLI::logging( "> Changing file permissions\n" );
|
||||
$shared_stat = stat( PATH_DATA );
|
||||
if ($shared_stat !== false) {
|
||||
workspaceTools::dirPerms( $workspace->path, $shared_stat['uid'], $shared_stat['gid'], $shared_stat['mode'] );
|
||||
WorkspaceTools::dirPerms( $workspace->path, $shared_stat['uid'], $shared_stat['gid'], $shared_stat['mode'] );
|
||||
} else {
|
||||
CLI::logging( CLI::error( "Could not get the shared folder permissions, not changing workspace permissions" ) . "\n" );
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user