docs: Make null booleans falsy in the docs helper

This commit is contained in:
Bjørn Erik Pedersen
2024-01-31 12:34:28 +01:00
parent bd66d30295
commit 51615440bf
3 changed files with 18 additions and 4 deletions

View File

@@ -195,7 +195,7 @@ url: %s
configProvider := func() docshelper.DocProvider {
conf := hugolib.DefaultConfig()
conf.CacheDir = "" // The default value does not make sense in the docs.
defaultConfig := parser.LowerCaseCamelJSONMarshaller{Value: conf}
defaultConfig := parser.NullBoolJSONMarshaller{Wrapped: parser.LowerCaseCamelJSONMarshaller{Value: conf}}
return docshelper.DocProvider{"config": defaultConfig}
}