feat(authorization): add delete connection checks

This commit is contained in:
Ali BARIN
2023-06-23 21:24:02 +00:00
parent 94e560c262
commit 181cb5f335

View File

@@ -11,6 +11,8 @@ const deleteConnection = async (
params: Params,
context: Context
) => {
context.currentUser.can('delete', 'Connection');
await context.currentUser
.$relatedQuery('connections')
.delete()