Skip to content

Commit 668a477

Browse files
Eisfunketechknowlogick
authored andcommitted
Fix trimming of markup section names (#4863)
Signed-off-by: Nicolas Lenz <[email protected]>
1 parent e48df3e commit 668a477

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

modules/setting/setting.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1155,7 +1155,7 @@ func NewContext() {
11551155

11561156
extensionReg := regexp.MustCompile(`\.\w`)
11571157
for _, sec := range Cfg.Section("markup").ChildSections() {
1158-
name := strings.TrimLeft(sec.Name(), "markup.")
1158+
name := strings.TrimPrefix(sec.Name(), "markup.")
11591159
if name == "" {
11601160
log.Warn("name is empty, markup " + sec.Name() + "ignored")
11611161
continue

0 commit comments

Comments
 (0)