Sha256: ad9227c3544d0d27a2919753589924dc59d5fea5c7a6f1c647ceab684b0e584c
Contents?: true
Size: 804 Bytes
Versions: 88
Compression:
Stored size: 804 Bytes
Contents
import { initialApiState } from '../../../services/api'; import { ANSIBLE_COLLECTION_DETAILS_REQUEST, ANSIBLE_COLLECTION_DETAILS_SUCCESS, ANSIBLE_COLLECTION_DETAILS_ERROR, } from './AnsibleCollectionDetailsConstants'; export default (state = initialApiState, action) => { switch (action.type) { case ANSIBLE_COLLECTION_DETAILS_REQUEST: { return state.set('loading', true); } case ANSIBLE_COLLECTION_DETAILS_SUCCESS: { const ansibleCollectionDetails = action.response; return state.merge({ ...ansibleCollectionDetails, loading: false, }); } case ANSIBLE_COLLECTION_DETAILS_ERROR: { return state.merge({ error: action.payload.message, loading: false, }); } default: { return state; } } };
Version data entries
88 entries across 88 versions & 1 rubygems