import { AnyAction } from "redux" ; import { Map } from "immutable" ; import { EthAddress } from "@joincivil/core" ; import { contractAddressesActions } from "../actionCreators/contractAddresses" ; export function contractAddresses ( state = Map < string , EthAddress > ( ) , action ) { switch ( action . type ) { case contractAddressesActions . SET_CONTRACT_ADDRESS : return state . set ( action . key , action . value ) ; default : return state ; } }