mirror of
https://github.com/balena-os/balena-supervisor.git
synced 2025-01-11 15:32:47 +00:00
Return when no appId
This commit is contained in:
parent
397fd6872b
commit
1e340f4fac
@ -31,7 +31,7 @@ module.exports = (secret) ->
|
|||||||
appId = req.body.appId
|
appId = req.body.appId
|
||||||
utils.mixpanelTrack('Spawn tty', appId)
|
utils.mixpanelTrack('Spawn tty', appId)
|
||||||
if !appId?
|
if !appId?
|
||||||
res.status(400).send('Missing app id')
|
return res.status(400).send('Missing app id')
|
||||||
knex('app').select().where({appId})
|
knex('app').select().where({appId})
|
||||||
.then ([ app ]) ->
|
.then ([ app ]) ->
|
||||||
if !app?
|
if !app?
|
||||||
@ -46,7 +46,7 @@ module.exports = (secret) ->
|
|||||||
appId = req.body.appId
|
appId = req.body.appId
|
||||||
utils.mixpanelTrack('Despawn tty', appId)
|
utils.mixpanelTrack('Despawn tty', appId)
|
||||||
if !appId?
|
if !appId?
|
||||||
res.status(400).send('Missing app id')
|
return res.status(400).send('Missing app id')
|
||||||
knex('app').select().where({appId})
|
knex('app').select().where({appId})
|
||||||
.then ([ app ]) ->
|
.then ([ app ]) ->
|
||||||
if !app?
|
if !app?
|
||||||
|
Loading…
Reference in New Issue
Block a user