Merge pull request 'by Robin at 20240525' (#505) from feat-IRONFANS-136-Robin into main
Reviewed-on: http://121.41.31.146:3000/wishpal_ironfan/service/pulls/505
This commit is contained in:
commit
d1e884f42f
|
@ -1097,7 +1097,7 @@ func (m *Mongo) DeleteToken(ctx *gin.Context, id int64) error {
|
||||||
func (m *Mongo) DeleteTokenByMid(ctx *gin.Context, mid int64) error {
|
func (m *Mongo) DeleteTokenByMid(ctx *gin.Context, mid int64) error {
|
||||||
col := m.getColToken()
|
col := m.getColToken()
|
||||||
|
|
||||||
err := col.Remove(ctx, qmgo.M{
|
_, err := col.RemoveAll(ctx, qmgo.M{
|
||||||
"mid": mid,
|
"mid": mid,
|
||||||
})
|
})
|
||||||
return err
|
return err
|
||||||
|
@ -1106,7 +1106,7 @@ func (m *Mongo) DeleteTokenByMid(ctx *gin.Context, mid int64) error {
|
||||||
func (m *Mongo) DeleteTokenByMids(ctx *gin.Context, mids []int64) error {
|
func (m *Mongo) DeleteTokenByMids(ctx *gin.Context, mids []int64) error {
|
||||||
col := m.getColToken()
|
col := m.getColToken()
|
||||||
|
|
||||||
err := col.Remove(ctx, qmgo.M{
|
_, err := col.RemoveAll(ctx, qmgo.M{
|
||||||
"mid": qmgo.M{
|
"mid": qmgo.M{
|
||||||
"$in": mids,
|
"$in": mids,
|
||||||
},
|
},
|
||||||
|
|
Loading…
Reference in New Issue