When I try to use headers object in the following code, I get the mentioned error. Without that, everything works fine.
getGitHubReadme : function(user, repo) {
var headers = {'Accept' : 'application/vnd.github.3.html'};
var repoReadMe = Async.runSync(function(done) {
github.repos.getReadme({headers: headers, user: user, repo: repo}, function(err, data) {
done(null, data);
});
});
return repoReadMe.result;
}
When I try to use headers object in the following code, I get the mentioned error. Without that, everything works fine. getGitHubReadme : function(user, repo) { var headers = {'Accept' : 'application/vnd.github.3.html'}; var repoReadMe = Async.runSync(function(done) { github.repos.getReadme({headers: headers, user: user, repo: repo}, function(err, data) { done(null, data); }); }); return repoReadMe.result; }
Am I missing something here?