Skip to content

Commit 880457b

Browse files
hqhq1025HAPI
andcommitted
fix: add non-null assertion for textChild.value
via [HAPI](https://hapi.run) Co-Authored-By: HAPI <noreply@hapi.run>
1 parent a63363d commit 880457b

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

web/src/lib/remark-strip-cjk-autolink.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ function visitLinks(node: MdastNode): void {
4444
child.url = child.url.slice(0, -punct.length)
4545

4646
// Strip from the link's text child
47-
textChild!.value = textChild!.value.slice(0, -punct.length)
47+
textChild!.value = textChild!.value!.slice(0, -punct.length)
4848

4949
// Insert the punctuation as a plain text node after the link
5050
const punctNode: MdastNode = { type: 'text', value: punct }

0 commit comments

Comments
 (0)