Enable ESLlint no-case-declarations (#30768)
This commit is contained in:
parent
a2c4ba2001
commit
f91f077985
5 changed files with 8 additions and 5 deletions
|
@ -72,9 +72,10 @@ export default function search(state = initialState, action) {
|
|||
});
|
||||
case SEARCH_EXPAND_REQUEST:
|
||||
return state.set('type', action.searchType).set('isLoading', true);
|
||||
case SEARCH_EXPAND_SUCCESS:
|
||||
case SEARCH_EXPAND_SUCCESS: {
|
||||
const results = action.searchType === 'hashtags' ? ImmutableOrderedSet(fromJS(action.results.hashtags)) : action.results[action.searchType].map(item => item.id);
|
||||
return state.updateIn(['results', action.searchType], list => list.union(results)).set('isLoading', false);
|
||||
}
|
||||
case SEARCH_HISTORY_UPDATE:
|
||||
return state.set('recent', ImmutableOrderedSet(fromJS(action.recent)));
|
||||
default:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue