File tree Expand file tree Collapse file tree 1 file changed +4
-5
lines changed Expand file tree Collapse file tree 1 file changed +4
-5
lines changed Original file line number Diff line number Diff line change @@ -1312,19 +1312,18 @@ Content-Security-Policy: default-src 'self' *.http://sometrustedwebsite.com
1312
1312
const express = require (" express" );
1313
1313
const app = express ();
1314
1314
const axios = require (" axios" );
1315
-
1315
+
1316
1316
app .post (" /user" , async (req , res ) => {
1317
1317
try {
1318
- const payload = { name: ' Aashita Iyer' , email: ' aashita.iyer@email.com' };
1319
-
1320
- const response = await axios .post (' http://httpbin.org/post' , payload);
1318
+ const payload = { name: " Aashita Iyer" , email: " aashita.iyer@email.com" };
1319
+ const response = await axios .post (" http://httpbin.org/post" , payload);
1321
1320
console .log (response .data );
1322
1321
res .status (200 ).json (response .data );
1323
1322
} catch (err) {
1324
1323
res .status (500 ).json ({ message: err });
1325
1324
}
1326
1325
});
1327
-
1326
+
1328
1327
app .listen (3000 , function () {
1329
1328
console .log (` App listening at http://localhost:3000/` );
1330
1329
});
You can’t perform that action at this time.
0 commit comments