Skip to content

Commit

Permalink
Change in get response field
Browse files Browse the repository at this point in the history
  • Loading branch information
jalish-Chauhan-Dicot-07 committed Apr 6, 2024
1 parent a1b50e3 commit dfbdcfb
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,12 @@ app.use(express.urlencoded({extended:true}));

app.get('/',(req,res)=>{
console.log(' / GET');
return res.send({status:200,message:`Hello ${req.query.name }`})
return res.send({status:200,data:`Hello ${req.query.name }`})
})

app.post('/post',(req,res)=>{
console.log(' / POST');
return res.send({status:200,data:"POST Request"})
return res.send({status:200,message:"POST Request"})
})


Expand Down

0 comments on commit dfbdcfb

Please sign in to comment.