Sha256: 1a2d85db1f352de3439f6ee87e088a151957033933430fa56083e9e0e0fcbe14
Contents?: true
Size: 549 Bytes
Versions: 15
Compression:
Stored size: 549 Bytes
Contents
import API from 'foremanReact/API'; import { insightsCloudUrl } from './InsightsCloudSyncHelpers'; import { INSIGHTS_CLOUD_SYNC_SUCCESS, INSIGHTS_CLOUD_SYNC_FAILURE, } from './InsightsCloudSyncConstants'; export const syncInsights = () => async dispatch => { try { await API.post(insightsCloudUrl('tasks')); dispatch({ type: INSIGHTS_CLOUD_SYNC_SUCCESS, payload: {}, }); } catch (error) { dispatch({ type: INSIGHTS_CLOUD_SYNC_FAILURE, payload: { error: error.message, }, }); } };
Version data entries
15 entries across 15 versions & 1 rubygems