Fix: url.Values map was not initialized (#14485)

Values map was not initialized, leading to error 500 on submission of initial configuration

Co-authored-by: 6543 <6543@obermui.de>
release/v1.15
PhilAtWysdom 2021-01-27 13:33:32 +00:00 committed by GitHub
parent 2e90a256be
commit af7f71207c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 0 deletions

View File

@ -27,6 +27,9 @@ type Flash struct {
}
func (f *Flash) set(name, msg string, current ...bool) {
if f.Values == nil {
f.Values = make(map[string][]string)
}
isShow := false
if (len(current) == 0 && FlashNow) ||
(len(current) > 0 && current[0]) {