diff --git a/README.md b/README.md index efc24f6..d85a6b5 100644 --- a/README.md +++ b/README.md @@ -85,7 +85,7 @@ SC.init({ Once authorized (or if you're accessing unprotected endpoints), you may now make calls to the SoundCloud API [documented here](https://developers.soundcloud.com/docs/api/reference). An example could be as follows: ```javascript -SC.get('/tracks/164497989', function(err, track) { +SC.get('/tracks/276882056', function(err, track) { if ( err ) { throw err; } else { diff --git a/lib/soundcloud.js b/lib/soundcloud.js index 32d482e..d6eeb47 100644 --- a/lib/soundcloud.js +++ b/lib/soundcloud.js @@ -1,6 +1,6 @@ 'use strict'; -var https = require('https'); +var https = require('follow-redirects').https; var qs = require('querystring'); var hostApi = 'api.soundcloud.com'; var hostConnect = 'https://soundcloud.com/connect'; diff --git a/package.json b/package.json index b8ab10f..e2e1eac 100644 --- a/package.json +++ b/package.json @@ -17,5 +17,6 @@ "node": ">=0.10.26" }, "dependencies": { + "follow-redirects": "^0.2.0" } }