b9cee4ba3c
Closes #49120
9 lines
286 B
Ruby
9 lines
286 B
Ruby
# frozen_string_literal: true
|
|
|
|
module CookiesHelper
|
|
def set_secure_cookie(key, value, httponly: false, permanent: false)
|
|
cookie_jar = permanent ? cookies.permanent : cookies
|
|
|
|
cookie_jar[key] = { value: value, secure: Gitlab.config.gitlab.https, httponly: httponly }
|
|
end
|
|
end
|