From d4fb86f50631143f53e03de5790bc428227e7170 Mon Sep 17 00:00:00 2001 From: Girish Ramakrishnan Date: Mon, 3 Oct 2016 14:31:24 -0700 Subject: [PATCH] debug out the backup list --- cloudron.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/cloudron.js b/cloudron.js index 081ef7a..efdd454 100644 --- a/cloudron.js +++ b/cloudron.js @@ -238,6 +238,8 @@ Cloudron.prototype.cloneApp = function (appId, newLocation, portBindings) { var backups = this.listAppBackups(appId); + console.log('Backups are ', backups); + var data = { location: newLocation, password: this._credentials.password, portBindings: portBindings, backupId: backups[0].id }; var res = request.post(this._origin + '/api/v1/apps/' + appId + '/clone').query({ access_token: this._credentials.accessToken }).send(data).end(); @@ -401,7 +403,7 @@ Cloudron.prototype.resetPassword = function (resetToken, password) { Cloudron.prototype.backupApp = function (appId) { var res = request.post(this._origin + '/api/v1/apps/' + appId + '/backup').query({ access_token: this._credentials.accessToken }).end(); - common.verifyResponse2xx(res, 'Could not schedule backup'); + common.verifyResponse2xx(res, 'Could not schedule a backup'); this.waitForApp(appId); };