Skip to content

Commit 4138b62

Browse files
committed
chore: fix lint
1 parent eeb35d1 commit 4138b62

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/to-have-text-content.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ function collectNormalizedText(element: ReactTestInstance) {
99

1010
function collectChildrenText(element: ReactTestInstance | string): string[] {
1111
if (typeof element === 'string') return [element];
12-
if (!element || !element.children) return [];
12+
if (!element?.children) return [];
1313

1414
const result: string[] = [];
1515
element.children.forEach((child) => {

0 commit comments

Comments
 (0)