diff options
Diffstat (limited to 'modules/setting/log.go')
-rw-r--r-- | modules/setting/log.go | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/modules/setting/log.go b/modules/setting/log.go index e666e2a027..008a419b09 100644 --- a/modules/setting/log.go +++ b/modules/setting/log.go @@ -32,9 +32,8 @@ func GetLogDescriptions() map[string]*LogDescription { descs := make(map[string]*LogDescription, len(logDescriptions)) for k, v := range logDescriptions { subLogDescriptions := make([]SubLogDescription, len(v.SubLogDescriptions)) - for i, s := range v.SubLogDescriptions { - subLogDescriptions[i] = s - } + copy(subLogDescriptions, v.SubLogDescriptions) + descs[k] = &LogDescription{ Name: v.Name, SubLogDescriptions: subLogDescriptions, |