UNPKG

lml-main

Version:

This is now a mono repository published into many standalone packages.

23 lines 1.18 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); var redux_observable_1 = require("redux-observable"); var cosmoui_1 = require("cosmoui"); var actions_1 = require("../actions"); exports.fetchCourierByIdSuccess = function (action$, store) { return action$.ofType(actions_1.FETCH_COURIER_BY_ID.SUCCESS) .map(function (action) { return actions_1.setCourierById(action.result); }); }; exports.fetchCouriersByIdBatchSuccess = function (action$, store) { return action$.ofType(actions_1.FETCH_COURIERS_BY_ID_BATCH.SUCCESS) .map(function (action) { return actions_1.setCouriersByIdBatch(action.result); }); }; exports.fetchCourierByIdError = function (action$, store) { return action$.ofType(actions_1.FETCH_COURIER_BY_ID.ERROR, actions_1.FETCH_COURIERS_BY_ID_BATCH.ERROR) .mapTo(cosmoui_1.notificationError('There was a problem fetching the courier details. Please try again')); }; exports.fetchCourierByIdEpics = redux_observable_1.combineEpics(exports.fetchCourierByIdSuccess, exports.fetchCouriersByIdBatchSuccess, exports.fetchCourierByIdError); //# sourceMappingURL=fetch-courier-by-id.js.map