Skip to content

Commit 16e498f

Browse files
authored
Merge pull request gothinkster#53 from foopang/fix-warnings
Fix warnings
2 parents 0a0c8f6 + 225f2d9 commit 16e498f

27 files changed

+31
-57
lines changed

src/agent.js

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
'use strict';
2-
31
import superagentPromise from 'superagent-promise';
42
import _superagent from 'superagent';
53

src/components/Article/ArticleMeta.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ const ArticleMeta = props => {
77
return (
88
<div className="article-meta">
99
<Link to={`@${article.author.username}`}>
10-
<img src={article.author.image} />
10+
<img src={article.author.image} alt={article.author.username} />
1111
</Link>
1212

1313
<div className="info">

src/components/Article/Comment.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ const Comment = props => {
1515
<Link
1616
to={`@${comment.author.username}`}
1717
className="comment-author">
18-
<img src={comment.author.image} className="comment-author-img" />
18+
<img src={comment.author.image} className="comment-author-img" alt={comment.author.username} />
1919
</Link>
2020
&nbsp;
2121
<Link

src/components/Article/CommentInput.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,8 @@ class CommentInput extends React.Component {
4242
<div className="card-footer">
4343
<img
4444
src={this.props.currentUser.image}
45-
className="comment-author-img" />
45+
className="comment-author-img"
46+
alt={this.props.currentUser.username} />
4647
<button
4748
className="btn btn-sm btn-primary"
4849
type="submit">

src/components/Article/index.js

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,5 @@
1-
'use strict';
2-
31
import ArticleMeta from './ArticleMeta';
42
import CommentContainer from './CommentContainer';
5-
import { Link } from 'react-router';
63
import React from 'react';
74
import agent from '../../agent';
85
import { connect } from 'react-redux';

src/components/ArticleList.js

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
'use strict';
2-
31
import ArticlePreview from './ArticlePreview';
42
import ListPagination from './ListPagination';
53
import React from 'react';

src/components/ArticlePreview.js

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
'use strict';
2-
31
import React from 'react';
42
import { Link } from 'react-router';
53
import agent from '../agent';
@@ -39,7 +37,7 @@ const ArticlePreview = props => {
3937
<div className="article-preview">
4038
<div className="article-meta">
4139
<Link to={`@${article.author.username}`}>
42-
<img src={article.author.image} />
40+
<img src={article.author.image} alt={article.author.username} />
4341
</Link>
4442

4543
<div className="info">

src/components/Editor.js

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
'use strict';
2-
31
import ListErrors from './ListErrors';
42
import React from 'react';
53
import agent from '../agent';

src/components/Header.js

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
'use strict';
2-
31
import React from 'react';
42
import { Link } from 'react-router';
53

@@ -59,7 +57,7 @@ const LoggedInView = props => {
5957
<Link
6058
to={`@${props.currentUser.username}`}
6159
className="nav-link">
62-
<img src={props.currentUser.image} className="user-pic" />
60+
<img src={props.currentUser.image} className="user-pic" alt={props.currentUser.username} />
6361
{props.currentUser.username}
6462
</Link>
6563
</li>

src/components/Home/MainView.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ const mapStateToProps = state => ({
6262
});
6363

6464
const mapDispatchToProps = dispatch => ({
65-
onTabClick: (tab, pager, payload) => dispatch({ type: 'CHANGE_TAB', tab, pager, payload })
65+
onTabClick: (tab, pager, payload) => dispatch({ type: CHANGE_TAB, tab, pager, payload })
6666
});
6767

6868
const MainView = props => {

0 commit comments

Comments
 (0)