Avoid 500 errors with long expiration dates in tokens
If a user created a personal access token with an expiration date far in advance, the date would be saved but a 500 error would be shown on display: ``` PG::DatetimeFieldOverflow: ERROR: date out of range for timestamp ``` To fix this, since we're comparing dates, we shouldn't use NOW in the SQL query. Instead, we use CURRENT_DATE. This fix is similar to https://gitlab.com/gitlab-org/gitlab-foss/-/merge_requests/25806. Closes https://gitlab.com/gitlab-org/gitlab/-/issues/26306
Showing
Please register or sign in to comment