diff options
author | Yamagishi Kazutoshi <ykzts@desire.sh> | 2017-05-21 00:31:47 +0900 |
---|---|---|
committer | Eugen Rochko <eugen@zeonfederated.com> | 2017-05-20 17:31:47 +0200 |
commit | 2e112e240666b62b8c3d4fa201fb24b841f6c92b (patch) | |
tree | f95f2eb5ae8156c10bf16894919d0ba5e3f34096 /app/javascript/mastodon/actions/search.js | |
parent | 812fe90ecaef58f1dbe16c3fdfea79e14e7bbc9d (diff) |
Improve eslint rules (#3147)
* Add semi to ESLint rules * Add padded-blocks to ESLint rules * Add comma-dangle to ESLint rules * add config/webpack and storyboard * add streaming/ * yarn test:lint -- --fix
Diffstat (limited to 'app/javascript/mastodon/actions/search.js')
-rw-r--r-- | app/javascript/mastodon/actions/search.js | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/app/javascript/mastodon/actions/search.js b/app/javascript/mastodon/actions/search.js index df3ae0db1..78c6109f7 100644 --- a/app/javascript/mastodon/actions/search.js +++ b/app/javascript/mastodon/actions/search.js @@ -1,4 +1,4 @@ -import api from '../api' +import api from '../api'; export const SEARCH_CHANGE = 'SEARCH_CHANGE'; export const SEARCH_CLEAR = 'SEARCH_CLEAR'; @@ -11,13 +11,13 @@ export const SEARCH_FETCH_FAIL = 'SEARCH_FETCH_FAIL'; export function changeSearch(value) { return { type: SEARCH_CHANGE, - value + value, }; }; export function clearSearch() { return { - type: SEARCH_CLEAR + type: SEARCH_CLEAR, }; }; @@ -34,8 +34,8 @@ export function submitSearch() { api(getState).get('/api/v1/search', { params: { q: value, - resolve: true - } + resolve: true, + }, }).then(response => { dispatch(fetchSearchSuccess(response.data)); }).catch(error => { @@ -46,7 +46,7 @@ export function submitSearch() { export function fetchSearchRequest() { return { - type: SEARCH_FETCH_REQUEST + type: SEARCH_FETCH_REQUEST, }; }; @@ -55,19 +55,19 @@ export function fetchSearchSuccess(results) { type: SEARCH_FETCH_SUCCESS, results, accounts: results.accounts, - statuses: results.statuses + statuses: results.statuses, }; }; export function fetchSearchFail(error) { return { type: SEARCH_FETCH_FAIL, - error + error, }; }; export function showSearch() { return { - type: SEARCH_SHOW + type: SEARCH_SHOW, }; }; |