UNPKG

make-shift-brew-ui

Version:

Common User Interface for the Brewfactory projects, modified for MakeShift Aleworks

28 lines (21 loc) 643 B
'use strict'; var debug = require('debug')('BrewUI:action'); var BrewConstants = require('../../constants/BrewConstants'); module.exports = function (context, payload, done) { var brewFetcher = context.fetcher.get('brew'); debug('dispatching STOP_BREW'); context.dispatch(BrewConstants.ActionTypes.STOP_BREW); // Create brewFetcher.stop({}) .then(function () { if(typeof done === 'function') { done(); } }) .catch(function (err) { debug(err); if(typeof done === 'function') { done(); } }); };