Skip to content

Commit da91f65

Browse files
committed
[fix] regarding [Bug]: Error on missing header #13
1 parent 4eec083 commit da91f65

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/main.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ export default class ObsidianFunctionPlot extends Plugin {
4141
const config: HeaderOptions = Object.assign(
4242
{},
4343
DEFAULT_HEADER_OPTIONS,
44-
parseYaml(header.match(/-{3,}([^]+?)-{3,}/)[1] || '')
44+
header ? parseYaml(header.match(/-{3,}([^]+?)-{3,}/)[1] || '') : {}
4545
)
4646

4747
// prepare options for call to FunctionPlotya

0 commit comments

Comments
 (0)