Fixing some bugs

This commit is contained in:
2021-10-27 14:40:18 +02:00
parent 034010e4ed
commit b5df5c7799
2 changed files with 3 additions and 1 deletions

View File

@@ -22,6 +22,7 @@ export default class LinksController {
await link.load('author', (query) => {
query.select('email')
})
await link.load('clicks')
return response.status(200).send({
link
})
@@ -60,6 +61,7 @@ export default class LinksController {
.preload('author', (query) => {
query.select('email')
})
.preload('clicks')
return response.status(200).send({
links
})

View File

@@ -44,6 +44,6 @@ export default class Update extends BaseCommand {
link.expire = DateTime.fromJSDate(new Date(this.expire || new Date())) ?? null
}
await link.save()
this.logger.info('The user was successfully updated!')
this.logger.info('The link was successfully updated!')
}
}