remove isValidatorSet
This commit is contained in:
parent
d56383fca5
commit
cff1ddf0d7
|
@ -8,7 +8,7 @@ import ValidatorsMenuWithPrice from '../../../components/General/ValidatorsMenuW
|
|||
import { CLIENT_SETUP_SUBTITLE } from '../../../constants'
|
||||
|
||||
const ClientSetup = () => {
|
||||
const [isValidatorSet, setIsValidatorSet] = useState(false)
|
||||
const [ , setIsValidatorSet] = useState(false)
|
||||
const [validatorCount, setValidatorCount] = useState(0)
|
||||
useEffect(() => {
|
||||
setIsValidatorSet(validatorCount > 0)
|
||||
|
|
|
@ -17,7 +17,7 @@ import {
|
|||
} from '../../redux/ValidatorOnboarding/KeyGeneration/slice'
|
||||
import {
|
||||
setSubStepAdvisories,
|
||||
setIsAdvisoriesComplete,
|
||||
|
||||
} from '../../redux/ValidatorOnboarding/Advisories/slice'
|
||||
|
||||
const ContinueButton = () => {
|
||||
|
@ -34,7 +34,7 @@ const ContinueButton = () => {
|
|||
const { activeStep, subStepValidatorSetup } = useSelector(
|
||||
(state: RootState) => state.validatorOnboarding,
|
||||
)
|
||||
const { subStepAdvisories, isAdvisoriesComplete, isValidatorSet } = useSelector(
|
||||
const { subStepAdvisories, isValidatorSet } = useSelector(
|
||||
(state: RootState) => state.advisories,
|
||||
)
|
||||
|
||||
|
|
|
@ -1,34 +1,30 @@
|
|||
import { createSlice, PayloadAction } from '@reduxjs/toolkit'
|
||||
|
||||
interface AdvisoriesState {
|
||||
subStepAdvisories: number
|
||||
isAdvisoriesComplete: boolean
|
||||
isValidatorSet: boolean
|
||||
subStepAdvisories: number
|
||||
isValidatorSet: boolean
|
||||
}
|
||||
|
||||
const initialState = {
|
||||
subStepAdvisories: 0,
|
||||
isAdvisoriesComplete: false,
|
||||
isValidatorSet: false,
|
||||
subStepAdvisories: 0,
|
||||
isAdvisoriesComplete: false,
|
||||
isValidatorSet: false,
|
||||
}
|
||||
|
||||
const AdvisoriesSlice = createSlice({
|
||||
name: 'execClient',
|
||||
initialState,
|
||||
reducers: {
|
||||
setSubStepAdvisories: (state: AdvisoriesState, action: PayloadAction<number>) => {
|
||||
state.subStepAdvisories = action.payload
|
||||
name: 'execClient',
|
||||
initialState,
|
||||
reducers: {
|
||||
setSubStepAdvisories: (state: AdvisoriesState, action: PayloadAction<number>) => {
|
||||
state.subStepAdvisories = action.payload
|
||||
},
|
||||
setIsValidatorSet: (state: AdvisoriesState, action: PayloadAction<boolean>) => {
|
||||
state.isValidatorSet = action.payload
|
||||
},
|
||||
},
|
||||
setIsAdvisoriesComplete: (state: AdvisoriesState, action: PayloadAction<boolean>) => {
|
||||
state.isAdvisoriesComplete = action.payload
|
||||
},
|
||||
setIsValidatorSet: (state: AdvisoriesState, action: PayloadAction<boolean>) => {
|
||||
state.isValidatorSet = action.payload
|
||||
},
|
||||
},
|
||||
})
|
||||
|
||||
export const { setSubStepAdvisories, setIsAdvisoriesComplete, setIsValidatorSet } =
|
||||
AdvisoriesSlice.actions
|
||||
export const { setSubStepAdvisories, setIsValidatorSet } =
|
||||
AdvisoriesSlice.actions
|
||||
|
||||
export default AdvisoriesSlice.reducer
|
||||
|
|
Loading…
Reference in New Issue