function actionChannel(pattern, buffer) {
  if (process.env.NODE_ENV !== 'production') {
    check(pattern, is.pattern, 'actionChannel(pattern,...): argument pattern is not valid')

    if (arguments.length > 1) {
      check(buffer, is.notUndef, 'actionChannel(pattern, buffer): argument buffer is undefined')
      check(buffer, is.buffer, `actionChannel(pattern, buffer): argument ${buffer} is not a valid buffer`)
    }
  }

  return makeEffect(effectTypes.ACTION_CHANNEL, { pattern, buffer })
}
channel(pattern, [buffer])    => creates a proxy channel for store actions