gitea/modules
zeripath b228a0aa44
Use index of the supported tags to choose user lang (#15452) (#15488)
Backport #15452

Fix #14793.

The previous implementation used the first return value of matcher.Match, which is the chosen language tag but may contain extensions such as de-DE-u-rg-chzzzz.

As mentioned in the documentation of language package, matcher.Match also returns the index of the supported tags, so I think it is better to use it rather than manipulate the returned language tag.

Co-authored-by: Naohisa Murakami <tiqwab.ch90@gmail.com>
2021-04-15 16:47:43 +02:00
..
analyze Speed up enry.IsVendor (#15213) (#15245) 2021-04-02 01:16:00 +02:00
auth Add SameSite setting for cookies (#14900) 2021-03-07 08:12:43 +00:00
avatar
base Add some Unit-Tests (#14500) 2021-01-28 19:08:11 +01:00
cache [Vendor] Update go-redis to v8.5.0 (#13749) 2021-02-10 21:28:32 +00:00
charset
context Prevent superfluous response.WriteHeader (#15456) (#15476) 2021-04-15 11:02:42 +01:00
convert Fix wrong user returned in API (#15139) (#15151) 2021-03-26 04:20:52 +01:00
cron
doctor Delete Labels & IssueLabels on Repo Delete too (#15039) 2021-03-19 21:01:24 +02:00
emoji Fix several render issues (#14986) 2021-03-16 00:20:05 +01:00
eventsource Migrate to use jsoniter instead of encoding/json (#14841) 2021-03-01 22:08:10 +01:00
forms Move repo.CloseIssuesViaCommitInAnyBranch to issue settings (#14965) 2021-03-16 02:00:52 +01:00
generate
git Fix ambiguous argument error on tags (#15432) (#15474) 2021-04-14 14:53:01 -04:00
gitgraph
graceful Fix regression from #14623 - use debug SVC handler only on interactive sessions (#15210) (#15211) 2021-03-31 20:49:46 +01:00
hcaptcha
highlight
httpcache
httplib Migrate to use jsoniter instead of encoding/json (#14841) 2021-03-01 22:08:10 +01:00
indexer Speed up enry.IsVendor (#15213) (#15245) 2021-04-02 01:16:00 +02:00
lfs Close file on invalid range (Addition to #15166) (#15268) (#15308) 2021-04-06 15:25:31 -04:00
log Migrate to use jsoniter instead of encoding/json (#14841) 2021-03-01 22:08:10 +01:00
markup Upgrade to bluemonday 1.0.7 (#15379) (#15380) 2021-04-09 19:41:30 -04:00
matchlist
metrics
migrations Add size to Save function (#15264) (#15270) 2021-04-04 12:04:55 -04:00
nosql [Vendor] Update go-redis to v8.5.0 (#13749) 2021-02-10 21:28:32 +00:00
notification fix double 'push tag' action feed (#15078) (#15083) 2021-03-21 14:51:31 +00:00
options
password
pprof
private Migrate to use jsoniter instead of encoding/json (#14841) 2021-03-01 22:08:10 +01:00
process Reduce data races (#14549) 2021-02-03 22:36:38 +01:00
public add 'fonts' into 'KnownPublicEntries' (#15188) (#15218) 2021-03-31 04:56:19 +02:00
queue Always set the merge base used to merge the commit (#15352) (#15385) 2021-04-10 14:08:30 +02:00
recaptcha Migrate to use jsoniter instead of encoding/json (#14841) 2021-03-01 22:08:10 +01:00
references
repofiles Remove possible resource leak (#15067) (#15082) 2021-03-21 17:07:37 +01:00
repository Fix potential copy lfs records failure when fork a repository (#15441) (#15485) 2021-04-15 16:13:14 +02:00
secret
session Migrate to use jsoniter instead of encoding/json (#14841) 2021-03-01 22:08:10 +01:00
setting Add reverse proxy configuration support for remote IP address (#14959) 2021-03-16 00:27:28 +02:00
ssh Make internal SSH server host key path configurable (#14918) 2021-03-08 03:43:59 +01:00
storage Add size to Save function (#15264) (#15270) 2021-04-04 12:04:55 -04:00
structs Make manual merge autodetection optional and add manual merge as merge method (#12543) 2021-03-03 22:41:23 -05:00
svg
sync
task Migrate to use jsoniter instead of encoding/json (#14841) 2021-03-01 22:08:10 +01:00
templates Prevent incorrect HTML escaping in swagger.json (#14957) 2021-03-11 23:43:04 -05:00
test Move middlewares to web/middleware (#14480) 2021-01-30 10:55:53 +02:00
timeutil Fix display since time round (#14226) 2021-01-28 13:29:22 +01:00
translation Use index of the supported tags to choose user lang (#15452) (#15488) 2021-04-15 16:47:43 +02:00
upload
uri
user
util [API] Add pagination to ListBranches (#14524) 2021-02-03 20:06:13 +01:00
validation
web Use index of the supported tags to choose user lang (#15452) (#15488) 2021-04-15 16:47:43 +02:00