Skip to content

Commit e8a12ed

Browse files
author
soliury
committed
little refactor
1 parent 17d259a commit e8a12ed

2 files changed

Lines changed: 7 additions & 7 deletions

File tree

src/components/CommentList.js

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ class CommentList extends Component {
7676
x: 0,
7777
y: y
7878
}
79-
})
79+
});
8080
});
8181

8282
row.setNativeProps({
@@ -91,7 +91,7 @@ class CommentList extends Component {
9191
_renderFooter(comment, authorName) {
9292
if (this.props.user) {
9393
return (
94-
<View style={styles.commentFooter}>
94+
<View key="commentFooter" style={styles.commentFooter}>
9595
<CommentUp
9696
replyId={comment.id}
9797
ups={comment.ups}
@@ -110,7 +110,7 @@ class CommentList extends Component {
110110
/>
111111
</TouchableOpacity>
112112
</View>
113-
)
113+
);
114114
}
115115
}
116116

@@ -135,7 +135,7 @@ class CommentList extends Component {
135135
ref={view=>this[comment.id]=view}
136136
key={comment.id}
137137
style={[styles.commentWrapper,focusStyle]}>
138-
<View style={[styles.imageWrapper]}>
138+
<View key="imageWrapper" style={[styles.imageWrapper]}>
139139
<TouchableOpacity onPress={()=>{
140140
this.props.router.toUser({
141141
userName: authorName
@@ -153,7 +153,7 @@ class CommentList extends Component {
153153
</Text>
154154
</View>
155155

156-
<View style={styles.commentContentWrapper}>
156+
<View key="commentContentWrapper" style={styles.commentContentWrapper}>
157157
<View style={styles.commentHeader}>
158158
<View style={styles.author}>
159159
<TouchableOpacity onPress={()=> this.props.onAuthorNamePress(authorName)}>

src/layouts/Comment.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,7 @@ class Comment extends Component {
132132
style={styles.submitIcon}
133133
/>
134134
</View>
135-
)
135+
);
136136
}
137137
return (
138138
<Icon
@@ -141,7 +141,7 @@ class Comment extends Component {
141141
color='rgba(0,0,0,0.35)'
142142
style={styles.submitIcon}
143143
/>
144-
)
144+
);
145145
}
146146

147147

0 commit comments

Comments
 (0)