Compare commits
2 Commits
366e9f2821
...
47df437cdd
| Author | SHA1 | Date |
|---|---|---|
|
|
47df437cdd | |
|
|
a9c57ef016 |
|
|
@ -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
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue