Skip to content

Commit

Permalink
Fix port settings for deprecation warnings. (#4042)
Browse files Browse the repository at this point in the history
  • Loading branch information
phasetr committed Jun 18, 2022
1 parent 00f4088 commit cbd643f
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions docs/Guides/Database.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ fastify.get('/user/:id', function(req, reply) {
)
})

fastify.listen(3000, err => {
fastify.listen({ port: 3000 }, err => {
if (err) throw err
console.log(`server listening on ${fastify.server.address().port}`)
})
Expand All @@ -64,7 +64,7 @@ fastify.get('/user/:id', function (req, reply) {
)
})

fastify.listen(3000, err => {
fastify.listen({ port: 3000 }, err => {
if (err) throw err
console.log(`server listening on ${fastify.server.address().port}`)
})
Expand Down Expand Up @@ -98,7 +98,7 @@ fastify.post('/foo', function (req, reply) {
})
})

fastify.listen(3000, err => {
fastify.listen({ port: 3000 }, err => {
if (err) throw err
console.log(`server listening on ${fastify.server.address().port}`)
})
Expand Down Expand Up @@ -145,7 +145,7 @@ fastify.get('/user/:id', function (req, reply) {
})
})

fastify.listen(3000, err => {
fastify.listen({ port: 3000 }, err => {
if (err) throw err
})
```
Expand All @@ -172,7 +172,7 @@ fastify.post('/foo', async function (req, reply) {
return { status: 'ok' }
})

fastify.listen(3000, err => {
fastify.listen({ port: 3000 }, err => {
if (err) throw err
console.log(`server listening on ${fastify.server.address().port}`)
})
Expand Down

0 comments on commit cbd643f

Please sign in to comment.