1
1
mirror of https://github.com/go-gitea/gitea synced 2024-11-04 17:24:26 +00:00
gitea/modules/markup
mappu fd76f090a2 markup: microoptimise for many short filenames in directory (#1534)
* markup: microoptimise for many short filenames in directory

Move strings.ToLower() after the early-return length check. This is a safe operation in all cases and should slightly improve directory listing performance when a directory contains many thousands of files with short filenames.

* markup: expand test cases for IsReadmeFile()
2017-05-09 22:20:22 +08:00
..
markup_test.go markup: microoptimise for many short filenames in directory (#1534) 2017-05-09 22:20:22 +08:00
markup.go markup: microoptimise for many short filenames in directory (#1534) 2017-05-09 22:20:22 +08:00