diff --git a/cmd/tools/vdoc/vdoc.v b/cmd/tools/vdoc/vdoc.v index cb4ddb11e1..5cabe6a7fd 100644 --- a/cmd/tools/vdoc/vdoc.v +++ b/cmd/tools/vdoc/vdoc.v @@ -156,6 +156,9 @@ fn (vd VDoc) get_file_name(mod string, out Output) string { } else if !cfg.is_multi && !os.is_dir(out.path) { name = os.file_name(out.path) } + if name == '' { + name = 'index' + } name = name + match out.typ { .html { '.html' } .markdown { '.md' }