title: TypeError: res.json is not a function
body: <p>I'm trying to send two json but It doesn't work. It prints <code>TypeError: res.json is not a function</code> but I don't get why It happens. Is there any ideas? Thank you !!</p>
  
  <pre><code>app.post('/danger', function response(req, res) {
      let placeId = req.body.data;
      let option = {
        uri: 'https://maps.googleapis.com/maps/api/directions/json?',
        qs: {
          origin:`place_id:${placeId[0]}`, destination: `place_id:${placeId[1]}`,
          language: 'en', mode: 'walking', alternatives: true, key: APIKey
        }
      };
      rp(option)
        .then(function(res) {
          let dangerRate = dangerTest(JSON.parse(res), riskGrid);
          res.json({ data: [res, dangerRate]});
        })
        .catch(function(err) {
          console.error("Failed to get JSON from Google API", err);
        })
  });
  </code></pre>