fetchival icon indicating copy to clipboard operation
fetchival copied to clipboard

GET body not empty

Open minipai opened this issue 10 years ago • 0 comments

Seems that if I do a GET after POST, opts.body of GET request will send body that sent by POST I had to modify fetchival to fix it.

    if (data) {
      opts.body = JSON.stringify(data)
    } else {
      delete opts.body
    }

another possible fix is let function fetchival return a new object

minipai avatar Sep 23 '15 08:09 minipai