mirror of
https://github.com/caddyserver/caddy.git
synced 2025-03-11 16:19:01 +01:00
Fix bad merge conflict, make tests pass
This commit is contained in:
parent
269a8b5fce
commit
a6521357e5
2 changed files with 3 additions and 8 deletions
|
@ -171,7 +171,7 @@ md5:$apr1$l42y8rex$pOA2VJ0x/0TwaFeAF9nX61`
|
||||||
|
|
||||||
htfh, err := ioutil.TempFile("", "basicauth-")
|
htfh, err := ioutil.TempFile("", "basicauth-")
|
||||||
if err != nil {
|
if err != nil {
|
||||||
t.Skipf("Error creating temp file (%v), will skip htpassword test")
|
t.Skip("Error creating temp file, will skip htpassword test")
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
defer os.Remove(htfh.Name())
|
defer os.Remove(htfh.Name())
|
||||||
|
|
|
@ -66,7 +66,7 @@ func DescribePlugins() string {
|
||||||
str += " " + name + "\n"
|
str += " " + name + "\n"
|
||||||
}
|
}
|
||||||
|
|
||||||
if len(eventHooks) > 0 {
|
if len(pl["event_hooks"]) > 0 {
|
||||||
str += "\nEvent hook plugins:\n"
|
str += "\nEvent hook plugins:\n"
|
||||||
for _, name := range pl["event_hooks"] {
|
for _, name := range pl["event_hooks"] {
|
||||||
str += " hook." + name + "\n"
|
str += " hook." + name + "\n"
|
||||||
|
@ -100,15 +100,10 @@ func ListPlugins() map[string][]string {
|
||||||
}
|
}
|
||||||
|
|
||||||
// List the event hook plugins
|
// List the event hook plugins
|
||||||
hooks := ""
|
|
||||||
eventHooks.Range(func(k, _ interface{}) bool {
|
eventHooks.Range(func(k, _ interface{}) bool {
|
||||||
hooks += " hook." + k.(string) + "\n"
|
p["event_hooks"] = append(p["event_hooks"], k.(string))
|
||||||
return true
|
return true
|
||||||
})
|
})
|
||||||
if hooks != "" {
|
|
||||||
str += "\nEvent hook plugins:\n"
|
|
||||||
str += hooks
|
|
||||||
}
|
|
||||||
|
|
||||||
// alphabetize the rest of the plugins
|
// alphabetize the rest of the plugins
|
||||||
var others []string
|
var others []string
|
||||||
|
|
Loading…
Reference in a new issue