diff options
author | Abdelmalek Ihdene <[email protected]> | 2019-12-15 14:58:01 -0500 |
---|---|---|
committer | Matt Holt <[email protected]> | 2019-12-15 12:58:01 -0700 |
commit | c3bcd967bd3be85c41ac5f630d496f0dc0d18115 (patch) | |
tree | 8bb555badd890eb1713dcc20d99ab81a3e98367f /admin.go | |
parent | 6ea121ddf8c5be6de892971782d6f0fe2938ebbf (diff) | |
download | caddy-c3bcd967bd3be85c41ac5f630d496f0dc0d18115.tar.gz caddy-c3bcd967bd3be85c41ac5f630d496f0dc0d18115.zip |
logging: Implement net writer (#2884)
* Implement UDP writer
* Implement Net Writer
* Utilize Caddy's address parsing functions
* A couple little fixes (see #2884)
Diffstat (limited to 'admin.go')
-rw-r--r-- | admin.go | 6 |
1 files changed, 6 insertions, 0 deletions
@@ -711,6 +711,12 @@ traverseLoop: return fmt.Errorf("unrecognized method %s", method) } } else { + // if we are "PUTting" a new resource, the key(s) in its path + // might not exist yet; that's OK but we need to make them as + // we go, while we still have a pointer from the level above + if v[part] == nil && method == http.MethodPut { + v[part] = make(map[string]interface{}) + } ptr = v[part] } |