Sha256: 5f275fe5601259f8c0804a7e84d53818fbb92d7a9bcd8fb2b2d32ad762e3e577
Contents?: true
Size: 719 Bytes
Versions: 61
Compression:
Stored size: 719 Bytes
Contents
import { selectDoesIntervalExist } from 'foremanReact/redux/middlewares/IntervalMiddleware/IntervalSelectors'; import { bulkSearchKey, pollTaskKey } from './helpers'; export const selectIsPollingTask = (state, key) => selectDoesIntervalExist(state, pollTaskKey(key)); export const selectIsPollingTaskComplete = (state, key) => { const taskKey = pollTaskKey(key); const { response } = state?.API[taskKey] || {}; if (response) { const { progress, pending, result } = response; return progress === 1 && pending === false && (result === 'success' || result === 'error'); } return false; }; export const selectIsPollingTasks = (state, key) => selectDoesIntervalExist(state, bulkSearchKey(key));
Version data entries
61 entries across 61 versions & 1 rubygems