Skip to content

Commit

Permalink
Merge pull request #1409 from Ezra-Chan/master
Browse files Browse the repository at this point in the history
fix: Array.prototype.reduce() requires an initial value(#1408)
  • Loading branch information
1uokun authored Jan 20, 2025
2 parents 5192e9d + 7950334 commit e8f255d
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion components/list/ListItem.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ const InternalListItem: React.ForwardRefRenderFunction<
<Text
style={itemStyles.Content}
{...numberOfLines}
children={children.reduce((a, b) => (a || '') + '' + (b || ''))}
children={children.reduce((a, b) => (a || '') + '' + (b || ''), '')}
/>
)
}
Expand Down
2 changes: 1 addition & 1 deletion components/view/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ class AntmView extends React.PureComponent<ViewInterface> {
return (
<Text
{...restProps}
children={children.reduce((a, b) => (a || '') + '' + (b || ''))}
children={children.reduce((a, b) => (a || '') + '' + (b || ''), '')}
/>
)
}
Expand Down

0 comments on commit e8f255d

Please sign in to comment.