1
0
Fork 0
forked from forgejo/forgejo

Avoid double-unescaping of form value (#26853) (#26863)

Backport #26853

The old `prepareQueryArg` did double-unescaping of form value.
This commit is contained in:
wxiaoguang 2023-09-01 21:15:00 +08:00 committed by GitHub
parent 93c36f395c
commit e8da63c24e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 6 additions and 23 deletions

View file

@ -368,7 +368,7 @@ func TestSearchIssues(t *testing.T) {
DecodeJSON(t, resp, &apiIssues)
assert.Len(t, apiIssues, expectedIssueCount)
since := "2000-01-01T00%3A50%3A01%2B00%3A00" // 946687801
since := "2000-01-01T00:50:01+00:00" // 946687801
before := time.Unix(999307200, 0).Format(time.RFC3339)
query := url.Values{}
query.Add("since", since)