Commit e9225942 authored by Ad Schellevis's avatar Ad Schellevis

send upload exceptions to syslog for google drive

parent 3f4d694f
...@@ -369,8 +369,13 @@ function backup_to_google_drive() ...@@ -369,8 +369,13 @@ function backup_to_google_drive()
} }
if (!is_null($target_filename)) { if (!is_null($target_filename)) {
log_error("backup configuration as " . $target_filename); log_error("backup configuration as " . $target_filename);
$configfiles[$target_filename] = $client->upload($config->system->remotebackup->GDriveFolderID->__toString(), try {
$target_filename, $confdata_enc); $configfiles[$target_filename] = $client->upload($config->system->remotebackup->GDriveFolderID->__toString(), $target_filename, $confdata_enc);
} catch (Exception $e) {
log_error("unable to upload " . $target_filename . " to Google Drive (" . $e . ")");
return array();
}
krsort($configfiles); krsort($configfiles);
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment