diff options
Diffstat (limited to 'src/server/api/endpoints/othello/match/cancel.ts')
| -rw-r--r-- | src/server/api/endpoints/othello/match/cancel.ts | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/server/api/endpoints/othello/match/cancel.ts b/src/server/api/endpoints/othello/match/cancel.ts new file mode 100644 index 0000000000..ee0f82a611 --- /dev/null +++ b/src/server/api/endpoints/othello/match/cancel.ts @@ -0,0 +1,9 @@ +import Matching from '../../../models/othello-matching'; + +module.exports = (params, user) => new Promise(async (res, rej) => { + await Matching.remove({ + parentId: user._id + }); + + res(); +}); |