Adding device Id for version 2 of native apps (#5505)
* Adding device Id for version 2 * Changing ids
Этот коммит содержится в:
коммит произвёл
Joram Wilander
родитель
3b0f7163ab
Коммит
ca7d3b6e7b
@@ -206,11 +206,6 @@ func attachDeviceId(c *Context, w http.ResponseWriter, r *http.Request) {
|
||||
return
|
||||
}
|
||||
|
||||
if !(strings.HasPrefix(deviceId, model.PUSH_NOTIFY_APPLE+":") || strings.HasPrefix(deviceId, model.PUSH_NOTIFY_ANDROID+":")) {
|
||||
c.SetInvalidParam("attachDevice", "deviceId")
|
||||
return
|
||||
}
|
||||
|
||||
// A special case where we logout of all other sessions with the same device id
|
||||
if err := app.RevokeSessionsForDeviceId(c.Session.UserId, deviceId, c.Session.Id); err != nil {
|
||||
c.Err = err
|
||||
|
||||
Ссылка в новой задаче
Block a user