title: Axios post isn't handling the response
body: <p>I am uploading images to Cloudinary and want to retrieve the image url after it is uploaded. It is uploading correctly and I can console.log the url on server side but afterwards the response is not handled in the axios call on the client side and no error messages appear.</p>
  
  <p>My client:</p>
  
  <pre><code>submitFile = () =&gt; {
      var formData = new FormData();
      formData.append('image', this.state.file, 'tmp_name');//this.state.file is not correct format compared to postman constructed
      axios.post('http://localhost:3000/upload', formData).then(function(response) {
        console.log(response);
      });
    }
  </code></pre>
  
  <p>My server: </p>
  
  <pre><code>  server.post('/upload', async (req, res, next) =&gt; {
      const upload = multer({ storage }).single('image')
      upload(req, res, function(err) {
        if (err) {
          return res.send(err)
        }
        const path = req.file.path
        cloudinary.uploader.upload(
          path,
          { public_id: `${filename()}` },
          async function(err, image) {
            if (err) return res.send(err)
            console.log('file uploaded to Cloudinary')
            // remove file from server
            const fs = require('fs')
            fs.unlinkSync(path)
          }
        ).then(result =&gt; {res.send(result)})
      })
  </code></pre>
  
  <p>Again I want to just be able to view the response and save it but everything after then .then doesn't execute.</p>