mirror of
https://codeberg.org/timelimit/timelimit-server.git
synced 2026-08-31 19:03:45 +02:00
Delete app activities when deleting device
This commit is contained in:
@@ -49,6 +49,14 @@ export async function removeDevice ({ database, familyId, deviceId, websocket }:
|
||||
transaction
|
||||
})
|
||||
|
||||
await database.appActivity.destroy({
|
||||
where: {
|
||||
familyId,
|
||||
deviceId
|
||||
},
|
||||
transaction
|
||||
})
|
||||
|
||||
// remove as current device
|
||||
await database.user.update({
|
||||
currentDevice: ''
|
||||
|
||||
Reference in New Issue
Block a user