mirror of
https://git.kescher.at/CatCatNya/catstodon.git
synced 2024-11-28 17:31:37 +01:00
14 lines
398 B
React
14 lines
398 B
React
|
import { SUGGESTIONS_FETCH_SUCCESS } from '../actions/suggestions';
|
||
|
import Immutable from 'immutable';
|
||
|
|
||
|
const initialState = Immutable.List();
|
||
|
|
||
|
export default function suggestions(state = initialState, action) {
|
||
|
switch(action.type) {
|
||
|
case SUGGESTIONS_FETCH_SUCCESS:
|
||
|
return Immutable.List(action.accounts.map(item => item.id));
|
||
|
default:
|
||
|
return state;
|
||
|
}
|
||
|
}
|