diff --git a/package.json b/package.json index 25b829b..ed9b16d 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "datasquirel", - "version": "1.0.4", + "version": "1.0.5", "description": "Cloud-based SQL data management tool", "main": "index.js", "scripts": { diff --git a/users/add-user.js b/users/add-user.js index d2e1311..a0d2f7b 100644 --- a/users/add-user.js +++ b/users/add-user.js @@ -69,10 +69,12 @@ module.exports = async function ({ key, payload, database }) { }); } ) - .write({ - payload, - database, - }) + .write( + JSON.stringify({ + payload, + database, + }) + ) .end(); }); diff --git a/users/login-user.js b/users/login-user.js index c315b3b..e70735d 100644 --- a/users/login-user.js +++ b/users/login-user.js @@ -106,10 +106,12 @@ module.exports = async function ({ key, payload, database, response, encryptionK }); } ) - .write({ - payload, - database, - }) + .write( + JSON.stringify({ + payload, + database, + }) + ) .end(); }); diff --git a/users/logout-user.js b/users/logout-user.js index 13f8740..b14f29f 100644 --- a/users/logout-user.js +++ b/users/logout-user.js @@ -4,7 +4,7 @@ * ============================================================================== * @param {Object} response - Http response object */ -module.exports = async function ({ response }) { +module.exports = function ({ response }) { /** * Check Encryption Keys * diff --git a/users/user-auth.js b/users/user-auth.js index eed113b..156e8e8 100644 --- a/users/user-auth.js +++ b/users/user-auth.js @@ -20,7 +20,7 @@ const decrypt = require("../functions/decrypt"); * @param {String} encryptionKey - Encryption Key * @param {String} encryptionSalt - Encryption Salt */ -module.exports = async function ({ request, encryptionKey, encryptionSalt }) { +module.exports = function ({ request, encryptionKey, encryptionSalt }) { /** * Grab the payload * diff --git a/utils/post.js b/utils/post.js index bb59d22..35ad378 100644 --- a/utils/post.js +++ b/utils/post.js @@ -68,7 +68,7 @@ module.exports = async function ({ key, payload }) { }); } ) - .write(payload) + .write(JSON.stringify(payload)) .end(); }); diff --git a/utils/upload-image.js b/utils/upload-image.js index fca47a2..68277df 100644 --- a/utils/upload-image.js +++ b/utils/upload-image.js @@ -65,7 +65,7 @@ module.exports = async function ({ key, payload }) { }); } ) - .write(payload) + .write(JSON.stringify(payload)) .end(); });