修复同步问题

This commit is contained in:
junleea 2024-12-15 19:29:49 +08:00
parent e441b554e8
commit a9c57ef016
1 changed files with 8 additions and 0 deletions

View File

@ -116,6 +116,10 @@ func AddUserSync(req proto.UserAddOrUpdate) uint {
if res.Error != nil {
return 0
}
res = DB.Exec("update users set created_at=null where id=?", req.ID)
if res.Error != nil {
return 0
}
return req.ID
}
@ -125,6 +129,10 @@ func UpdateUserSync(req proto.UserAddOrUpdate) uint {
if res.Error != nil {
return 0
}
res = DB.Exec("update users set created_at=null where id=?", req.ID)
if res.Error != nil {
return 0
}
return req.ID
}