updates
This commit is contained in:
parent
1eb11ede15
commit
224dbf4175
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "datasquirel",
|
||||
"version": "1.0.5",
|
||||
"version": "1.0.6",
|
||||
"description": "Cloud-based SQL data management tool",
|
||||
"main": "index.js",
|
||||
"scripts": {
|
||||
|
@ -35,12 +35,17 @@ module.exports = async function ({ key, payload, database }) {
|
||||
* @description make a request to datasquirel.com
|
||||
*/
|
||||
const httpResponse = await new Promise((resolve, reject) => {
|
||||
https
|
||||
.request(
|
||||
const reqPayload = JSON.stringify({
|
||||
payload,
|
||||
database,
|
||||
});
|
||||
|
||||
const httpsRequest = https.request(
|
||||
{
|
||||
method: "POST",
|
||||
headers: {
|
||||
"Content-Type": "application/json",
|
||||
"Content-Length": reqPayload.length,
|
||||
Authorization: key,
|
||||
},
|
||||
port: 443,
|
||||
@ -68,14 +73,9 @@ module.exports = async function ({ key, payload, database }) {
|
||||
reject(err);
|
||||
});
|
||||
}
|
||||
)
|
||||
.write(
|
||||
JSON.stringify({
|
||||
payload,
|
||||
database,
|
||||
})
|
||||
)
|
||||
.end();
|
||||
);
|
||||
httpsRequest.write(reqPayload);
|
||||
httpsRequest.end();
|
||||
});
|
||||
|
||||
/** ********************************************** */
|
||||
|
@ -72,12 +72,17 @@ module.exports = async function ({ key, payload, database, response, encryptionK
|
||||
* @description make a request to datasquirel.com
|
||||
*/
|
||||
const httpResponse = await new Promise((resolve, reject) => {
|
||||
https
|
||||
.request(
|
||||
const reqPayload = JSON.stringify({
|
||||
payload,
|
||||
database,
|
||||
});
|
||||
|
||||
const httpsRequest = https.request(
|
||||
{
|
||||
method: "POST",
|
||||
headers: {
|
||||
"Content-Type": "application/json",
|
||||
"Content-Length": reqPayload.length,
|
||||
Authorization: key,
|
||||
},
|
||||
port: 443,
|
||||
@ -105,14 +110,10 @@ module.exports = async function ({ key, payload, database, response, encryptionK
|
||||
reject(err);
|
||||
});
|
||||
}
|
||||
)
|
||||
.write(
|
||||
JSON.stringify({
|
||||
payload,
|
||||
database,
|
||||
})
|
||||
)
|
||||
.end();
|
||||
);
|
||||
|
||||
httpsRequest.write(reqPayload);
|
||||
httpsRequest.end();
|
||||
});
|
||||
|
||||
/** ********************************************** */
|
||||
|
@ -34,12 +34,14 @@ module.exports = async function ({ key, payload }) {
|
||||
* @description make a request to datasquirel.com
|
||||
*/
|
||||
const httpResponse = await new Promise((resolve, reject) => {
|
||||
https
|
||||
.request(
|
||||
const reqPayload = JSON.stringify(payload);
|
||||
|
||||
const httpsRequest = https.request(
|
||||
{
|
||||
method: "POST",
|
||||
headers: {
|
||||
"Content-Type": "application/json",
|
||||
"Content-Length": reqPayload.length,
|
||||
Authorization: key,
|
||||
},
|
||||
port: 443,
|
||||
@ -67,9 +69,10 @@ module.exports = async function ({ key, payload }) {
|
||||
reject(err);
|
||||
});
|
||||
}
|
||||
)
|
||||
.write(JSON.stringify(payload))
|
||||
.end();
|
||||
);
|
||||
|
||||
httpsRequest.write(reqPayload);
|
||||
httpsRequest.end();
|
||||
});
|
||||
|
||||
/** ********************************************** */
|
||||
|
@ -31,12 +31,14 @@ module.exports = async function ({ key, payload }) {
|
||||
* @description make a request to datasquirel.com
|
||||
*/
|
||||
const httpResponse = await new Promise((resolve, reject) => {
|
||||
https
|
||||
.request(
|
||||
const reqPayload = JSON.stringify(payload);
|
||||
|
||||
const httpsRequest = https.request(
|
||||
{
|
||||
method: "POST",
|
||||
headers: {
|
||||
"Content-Type": "application/json",
|
||||
"Content-Length": reqPayload.length,
|
||||
Authorization: key,
|
||||
},
|
||||
port: 443,
|
||||
@ -64,9 +66,10 @@ module.exports = async function ({ key, payload }) {
|
||||
reject(err);
|
||||
});
|
||||
}
|
||||
)
|
||||
.write(JSON.stringify(payload))
|
||||
.end();
|
||||
);
|
||||
|
||||
httpsRequest.write(reqPayload);
|
||||
httpsRequest.end();
|
||||
});
|
||||
|
||||
/** ********************************************** */
|
||||
|
Loading…
Reference in New Issue
Block a user