Skip to content

Commit 876db60

Browse files
author
Montana Flynn
committed
Fix error checking bug
1 parent 81fbf54 commit 876db60

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

src/targets/go/native.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,10 +62,11 @@ module.exports = function (source, options) {
6262
if (source.postData.text) {
6363
code.push(util.format('\tpayload := strings.NewReader(%s)', JSON.stringify(source.postData.text)));
6464
code.push(util.format('\treq, %s := http.NewRequest("%s", url, payload)', errorPlaceholder, source.method));
65-
errorCheck();
6665
} else {
6766
code.push(util.format('\treq, %s := http.NewRequest("%s", url, nil)', errorPlaceholder, source.method));
6867
}
68+
69+
errorCheck();
6970

7071
// Add headers
7172
Object.keys(source.allHeaders).map(function (key) {

0 commit comments

Comments
 (0)