How to use the probot/lib/logger.debug function in probot

To help you get started, we’ve selected a few probot examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github integrations / slack / lib / middleware / route-action.js View on Github external
module.exports = function route(req, res, next) {
  const action = req.body.callback_id.substr(0, req.body.callback_id.indexOf('-'));

  if (action) {
    logger.debug({ ...req.body, token: undefined }, 'Action received from Slack');
    // Append action derived from callback_id to the request URL to route accordingly
    req.url += `:${action}`;
  }

  next();
};