Skip to content

Commit

Permalink
Merge pull request #380 from Kostov6/bugfix/nill-pointer
Browse files Browse the repository at this point in the history
`fullContent[0].docAst` could be nil
  • Loading branch information
RadaBDimitrova authored Jan 29, 2025
2 parents 702e2d4 + 58899ad commit 55e4588
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/workers/document/document_worker.go
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ func (d *Worker) process(ctx context.Context, b *bytes.Buffer, n *manifest.Node)
fullContent = append(fullContent, dc)
}

if fullContent[0].docAst.Kind() == ast.KindDocument {
if fullContent[0].docAst != nil && fullContent[0].docAst.Kind() == ast.KindDocument {
firstDoc := fullContent[0].docAst.(*ast.Document)
docs := []frontmatter.NodeMeta{}
for _, astNode := range fullContent {
Expand Down

0 comments on commit 55e4588

Please sign in to comment.