Skip to content
This repository has been archived by the owner on Nov 29, 2021. It is now read-only.

Commit

Permalink
feat: update batchDelete of yancey-music
Browse files Browse the repository at this point in the history
  • Loading branch information
YanceyOfficial committed Jan 9, 2020
1 parent 8a80a77 commit 140eafe
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/yancey-music/yancey-music.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,13 @@ export class YanceyMusicService {
}

public async batchDelete(ids: string[]): Promise<BatchDeleteModel> {
return this.yanceyMusicModel.deleteMany({
const res = await this.yanceyMusicModel.deleteMany({
_id: { $in: ids },
})

return {
...res,
ids,
}
}
}

0 comments on commit 140eafe

Please sign in to comment.