New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

strike-api

Package Overview
Dependencies
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

strike-api - npm Package Compare versions

Comparing version 0.0.2 to 0.0.3

.eslintrc

26

lib/strike.js

@@ -19,3 +19,3 @@ 'use strict';

.then(function(res) {
return res.body
return res.body;
});

@@ -32,3 +32,3 @@ };

.then(function(res) {
return res.body
return res.body;
});

@@ -44,3 +44,3 @@ };

.then(function(res) {
return res.body
return res.body;
});

@@ -57,6 +57,21 @@ };

.then(function(res) {
return res.body
return res.body;
});
};
var top = function(category) {
var uri = endpoint + 'torrents/top/';
category = category || 'all';
return client
.get(uri)
.query({ category: category })
.end()
.then(function(res) {
return res.body;
});
};
module.exports = {

@@ -66,3 +81,4 @@ info: info,

countTotal: countTotal,
search: search
search: search,
top: top
};

5

package.json
{
"name": "strike-api",
"version": "0.0.2",
"version": "0.0.3",
"description": "Strike Search API client",

@@ -24,2 +24,5 @@ "main": "lib/strike.js",

"devDependencies": {
"gulp": "^3.8.11",
"gulp-eslint": "^0.7.0",
"gulp-mocha": "^2.0.0",
"mocha": "^2.2.1"

@@ -26,0 +29,0 @@ },

@@ -1,2 +0,4 @@

var assert = require("assert");
'use strict';
var assert = require('assert');
var strike = require('../lib/strike');

@@ -21,3 +23,3 @@

});
})
});
});

@@ -36,3 +38,3 @@

});
})
});
});

@@ -57,3 +59,3 @@

});
})
});
});

@@ -72,4 +74,23 @@

});
})
})
});
});
describe('#top()', function(){
it('should return top for given category', function(done) {
strike.top('Anime').then(function(result) {
var status = result[0];
var data = result[1];
assert.equal(200, status.statuscode);
assert.ok(data.length > 0);
assert.equal('Anime', data[0].torrent_category);
done();
}).catch(function(err) {
done(err);
});
});
});
});

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

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

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc