mirror of
https://github.com/caddyserver/caddy.git
synced 2025-06-05 12:00:29 +08:00
Replace Open with Stat
This commit is contained in:
@ -32,7 +32,7 @@ func init() {
|
||||
p.cfg.Root = p.tkn()
|
||||
|
||||
// Ensure root folder exists
|
||||
_, err := os.Open(p.cfg.Root)
|
||||
_, err := os.Stat(p.cfg.Root)
|
||||
if err != nil {
|
||||
if os.IsNotExist(err) {
|
||||
// Allow this, because the folder might appear later.
|
||||
|
Reference in New Issue
Block a user