MM-41211: Adds ability to set SessionLengthSSOInDays to a decimal. (#19396)
* MM-41211: Accepts a decimal for the SSO session length. * MM-41211: Fixes test and logic error. * MM-41211: Validates session length is minimum 1 hour. * MM-41211: Tricking the CI to allow an empty string. * Fixes a test error and some lint changes. * Fix error. * Reverting IDE change. Co-authored-by: Mattermod <mattermod@users.noreply.github.com>
Этот коммит содержится в:
@@ -2080,7 +2080,7 @@ func attachDeviceId(c *Context, w http.ResponseWriter, r *http.Request) {
|
||||
}
|
||||
|
||||
c.App.ClearSessionCacheForUser(c.AppContext.Session().UserId)
|
||||
c.App.SetSessionExpireInDays(c.AppContext.Session(), *c.App.Config().ServiceSettings.SessionLengthMobileInDays)
|
||||
c.App.SetSessionExpireInHours(c.AppContext.Session(), *c.App.Config().ServiceSettings.SessionLengthMobileInHours())
|
||||
|
||||
maxAge := *c.App.Config().ServiceSettings.SessionLengthMobileInDays * 60 * 60 * 24
|
||||
|
||||
|
||||
Ссылка в новой задаче
Block a user