logs: use %o to format error
otherwise, they are printed as multi-line and this messes up tail+date formatting
This commit is contained in:
@@ -134,7 +134,7 @@ function upload(apiConfig, backupFilePath, sourceStream, callback) {
|
||||
|
||||
s3.upload(params, { partSize, queueSize: 3 }, function (error, data) {
|
||||
if (error) {
|
||||
debug('Error uploading [%s]: s3 upload error.', backupFilePath, error);
|
||||
debug(`upload: [${backupFilePath}] s3 upload error. %o`, error);
|
||||
return callback(new BoxError(BoxError.EXTERNAL_ERROR, `Error uploading ${backupFilePath}. Message: ${error.message} HTTP Code: ${error.code}`));
|
||||
}
|
||||
|
||||
@@ -201,7 +201,7 @@ class S3MultipartDownloadStream extends Readable {
|
||||
if (S3_NOT_FOUND(error)) {
|
||||
this.destroy(new BoxError(BoxError.NOT_FOUND, `Backup not found: ${this._path}`));
|
||||
} else {
|
||||
debug(`download: ${this._path} s3 stream error.`, error);
|
||||
debug(`download: ${this._path} s3 stream error. %o`, error);
|
||||
this.destroy(new BoxError(BoxError.EXTERNAL_ERROR, `Error multipartDownload ${this._path}. Message: ${error.message} HTTP Code: ${error.code}`));
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user