diff options
author | Matthew Holt <[email protected]> | 2019-12-29 13:16:34 -0700 |
---|---|---|
committer | Matthew Holt <[email protected]> | 2019-12-29 13:16:34 -0700 |
commit | fdabac51a8c8801840679a24e371f23013b021bb (patch) | |
tree | 90ca5dfd899a98b702e86886b113628b420aec94 /modules.go | |
parent | 95d944613bffce1cee3783568ae229e116168ba4 (diff) | |
download | caddy-fdabac51a8c8801840679a24e371f23013b021bb.tar.gz caddy-fdabac51a8c8801840679a24e371f23013b021bb.zip |
Improve docs, especially w.r.t. placeholders and template actions
Diffstat (limited to 'modules.go')
-rw-r--r-- | modules.go | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/modules.go b/modules.go index b036bea15..46fdd3b91 100644 --- a/modules.go +++ b/modules.go @@ -75,16 +75,16 @@ type ModuleInfo struct { // label is the module name, and the labels before that constitute // the namespace (or scope). // -// Thus, a module ID has the form: <namespace>.<id> +// Thus, a module ID has the form: <namespace>.<name> // // An ID with no dot has the empty namespace, which is appropriate // for app modules (these are "top-level" modules that Caddy core // loads and runs). // -// Module IDs should be lowercase and use underscore (_) instead of +// Module IDs should be lowercase and use underscores (_) instead of // spaces. // -// Example valid names: +// Examples of valid IDs: // - http // - http.handlers.file_server // - caddy.logging.encoders.json @@ -92,7 +92,7 @@ type ModuleID string // Namespace returns the namespace (or scope) portion of a module ID, // which is all but the last label of the ID. If the ID has only one -// label, then +// label, then the namespace is empty. func (id ModuleID) Namespace() string { lastDot := strings.LastIndex(string(id), ".") if lastDot < 0 { |