remove unused actions and fix test
This commit is contained in:
parent
e3409b3aae
commit
fe8a928317
5 changed files with 10 additions and 61 deletions
|
@ -1,21 +1,12 @@
|
|||
import actions from 'content/actions';
|
||||
|
||||
const defaultState = {
|
||||
enabled: false,
|
||||
keyword: '',
|
||||
found: false,
|
||||
};
|
||||
|
||||
export default function reducer(state = defaultState, action = {}) {
|
||||
switch (action.type) {
|
||||
case actions.FIND_SHOW:
|
||||
return Object.assign({}, state, {
|
||||
enabled: true,
|
||||
});
|
||||
case actions.FIND_HIDE:
|
||||
return Object.assign({}, state, {
|
||||
enabled: false,
|
||||
});
|
||||
case actions.FIND_SET_KEYWORD:
|
||||
return Object.assign({}, state, {
|
||||
keyword: action.keyword,
|
||||
|
|
Reference in a new issue