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>
Этот коммит содержится в:
mkraft
2022-02-14 12:06:47 -05:00
коммит произвёл GitHub
родитель 10c8c84704
Коммит 7398451030
15 изменённых файлов: 76 добавлений и 54 удалений

Просмотреть файл

@@ -131,7 +131,7 @@ func TestHandlerServeCSRFToken(t *testing.T) {
IsOAuth: false,
}
session.GenerateCSRF()
th.App.SetSessionExpireInDays(session, 1)
th.App.SetSessionExpireInHours(session, 24)
session, err := th.App.CreateSession(session)
if err != nil {
t.Errorf("Expected nil, got %s", err)