Socket
Socket
Sign inDemoInstall

octonode

Package Overview
Dependencies
51
Maintainers
1
Versions
67
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 0.9.3 to 0.9.4

.travis.yml

13

lib/octonode/repo.js

@@ -229,2 +229,15 @@ // Generated by CoffeeScript 1.12.7

Repo.prototype.releaseByTag = function(tag, cb) {
return this.client.get("/repos/" + this.name + "/releases/tags/" + tag, function(err, s, b, h) {
if (err) {
return cb(err);
}
if (s !== 200) {
return cb(new Error("Repo releaseByTag error"));
} else {
return cb(null, b, h);
}
});
};
Repo.prototype.createRelease = function(release, cb) {

@@ -231,0 +244,0 @@ return this.client.post("/repos/" + this.name + "/releases", release, function(err, s, b, h) {

8

package.json
{
"name": "octonode",
"version": "0.9.3",
"version": "0.9.4",
"author": "Pavan Kumar Sunkara <pavan.sss1991@gmail.com> (http://pksunkara.github.com)",

@@ -15,3 +15,3 @@ "description": "nodejs wrapper for github v3 api",

"scripts": {
"test": "vows --spec $(find test -name '*.js')",
"test": "vows --spec test/auth/index.js",
"lib": "./node_modules/coffee-script/bin/cake lib",

@@ -22,3 +22,3 @@ "watch": "./node_modules/coffee-script/bin/cake watch"

"bluebird": "^3.5.0",
"deep-extend": "^0.5.1",
"deep-extend": "^0.6.0",
"randomstring": "^1.1.5",

@@ -29,3 +29,3 @@ "request": "^2.72.0"

"coffee-script": "^1.12.4",
"nock": "^8.0.0",
"nock": "^9.4.3",
"vows": "^0.8.1"

@@ -32,0 +32,0 @@ },

@@ -232,2 +232,18 @@ # octonode [![Gitter chat](https://badges.gitter.im/pksunkara/octonode.svg)](https://gitter.im/pksunkara/octonode)

## Async / Promises
If you would like to work with promises rather than callbacks, you can call the promise based version of any of the api calls by appending `Async` to the function call.
For example `prs()` becomes `prsAsync()` like this:
```js
async function getPullRequests () {
const client = github.client(config.githubAccessToken)
const repo = client.repo('pksunkara/octonode')
const result = await repo.prsAsync({ per_page: 100 })
return result[0]
}
```
## Pagination

@@ -234,0 +250,0 @@

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc