Add active scope to Codium model and set on delete (#11)
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
2020-10-13 10:16:21 -05:00
parent a0b5003087
commit 597c269cd9
2 changed files with 6 additions and 1 deletions

View File

@@ -88,7 +88,8 @@ class FormCode extends Controller {
const code = await Codium.findOne({UUID: req.params.CodiumId})
if ( !code ) return res.status(404).message('Unable to find code with that ID.').api({})
await code.delete()
code.Active = false
await code.save()
return res.api({})
}
}