Files
alexis/lib/components/network/reducer.js
2023-08-01 12:47:58 +02:00

13 lines
282 B
JavaScript

'use strict'
const {RECEIVE_NETWORK} = require('./action_constants')
module.exports = (state = {}, action) => {
switch (action.type) {
case RECEIVE_NETWORK:
return Object.assign({}, state, {
network: action.network
})
default:
return state
}
}