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

apiquery

Package Overview
Dependencies
Maintainers
1
Versions
24
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

apiquery - npm Package Compare versions

Comparing version 0.1.19 to 0.1.20

53

apiquery.js

@@ -54,9 +54,3 @@ 'use strict';

function ioMock() {
var _console;
for (var _len = arguments.length, initParams = Array(_len), _key = 0; _key < _len; _key++) {
initParams[_key] = arguments[_key];
}
__DEV__ && (_console = console).log.apply(_console, ['ioMock'].concat(initParams));
// __DEV__ && console.log('ioMock', ...initParams);
// const socket = io(...params)

@@ -69,4 +63,4 @@ var mock = {

on: function on() {
for (var _len2 = arguments.length, params = Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {
params[_key2] = arguments[_key2];
for (var _len = arguments.length, params = Array(_len), _key = 0; _key < _len; _key++) {
params[_key] = arguments[_key];
}

@@ -77,4 +71,4 @@

use: function use() {
for (var _len3 = arguments.length, params = Array(_len3), _key3 = 0; _key3 < _len3; _key3++) {
params[_key3] = arguments[_key3];
for (var _len2 = arguments.length, params = Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {
params[_key2] = arguments[_key2];
}

@@ -90,13 +84,7 @@

recreateSocket: function recreateSocket() {
var _console2;
for (var _len4 = arguments.length, newInitParams = Array(_len4), _key4 = 0; _key4 < _len4; _key4++) {
newInitParams[_key4] = arguments[_key4];
}
__DEV__ && (_console2 = console).log.apply(_console2, ['recreateSocket'].concat(newInitParams));
// __DEV__ && console.log('recreateSocket', ...newInitParams);
if (mock.connection && mock.connection.disconnect) {
mock.connection.disconnect();
}
mock.connection = _socketIoUniversal2.default.apply(undefined, newInitParams);
mock.connection = _socketIoUniversal2.default.apply(undefined, arguments);
mock.events.forEach(function (event) {

@@ -113,16 +101,10 @@ var _mock$connection2;

mock.connection.recreateSocket = function () {
var _console3;
for (var _len5 = arguments.length, newInitParams2 = Array(_len5), _key5 = 0; _key5 < _len5; _key5++) {
newInitParams2[_key5] = arguments[_key5];
}
__DEV__ && (_console3 = console).log.apply(_console3, ['recreateSocket2'].concat(newInitParams2));
return mock.recreateSocket.apply(mock, newInitParams2);
// __DEV__ && console.log('recreateSocket2', ...newInitParams2);
return mock.recreateSocket.apply(mock, arguments);
};
__DEV__ && console.log('recreateConnection');
// __DEV__ && console.log('recreateConnection');
return mock.connection;
}
};
return mock.recreateSocket.apply(mock, initParams);
return mock.recreateSocket.apply(mock, arguments);
}

@@ -494,8 +476,9 @@

socket = _wsConnections$key[2];
// __DEV__ && this.log.trace('[api] prepare reconnect @@', socket);
// // __DEV__ && console.log('prepare reconnect @@', socket);
// if (!socket.recreateSocket) {
// // __DEV__ && console.log('!socket.recreateSocket', socket);
// }
__DEV__ && _this3.log.trace('[api] prepare reconnect @@', socket);
__DEV__ && console.log('prepare reconnect @@', socket);
if (!socket.recreateSocket) {
__DEV__ && console.log('!socket.recreateSocket', socket);
}
socket.recreateSocket(path, options);

@@ -601,2 +584,2 @@ // socket.disconnect();

exports.default = ApiClient;
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uL3NyYy9hcGlxdWVyeS5qcyJdLCJuYW1lcyI6WyJGRVRDSF9QQVJBTVMiLCJpb01vY2siLCJpbml0UGFyYW1zIiwiX19ERVZfXyIsImxvZyIsIm1vY2siLCJNYW5hZ2VyIiwiU29ja2V0IiwiY29ubmVjdGlvbiIsImV2ZW50cyIsIm9uIiwicGFyYW1zIiwicHVzaCIsInVzZSIsImRpc2Nvbm5lY3QiLCJyZWNyZWF0ZVNvY2tldCIsIm5ld0luaXRQYXJhbXMiLCJmb3JFYWNoIiwiZXZlbnQiLCJuYW1lIiwibmV3SW5pdFBhcmFtczIiLCJjb25zb2xlIiwiQXBpQ2xpZW50IiwidGhyb3dFcnJvciIsImVyciIsInJlcyIsInJlcSIsInNob3dFcnJvciIsInN0ciIsIkpTT04iLC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sYWluT2JqZWN0KGVycikgPyBKU09OLnN0cmluZ2lmeShlcnIsIG51bGwsIDIpIDogZXJyfVxuICByZXE6XG4ke0pTT04uc3RyaW5naWZ5KHJlcSwgbnVsbCwgMil9XG4gIGpzb246XG4ke0pTT04uc3RyaW5naWZ5KHJlcy5qc29uLCBudWxsLCAyKX1cbj09PT09PT09PT09PT09XFxcbmA7XG4gICAgICB0aGlzLmxvZy5lcnJvcihzdHIpO1xuICAgIH1cbiAgICBjb25zdCBtZXNzYWdlID0gZXJyICYmIGVyci5tZXNzYWdlIHx8IGVycjtcbiAgICBjb25zdCBlcnIyID0gbmV3IEVycm9yKGlzUGxhaW5PYmplY3QobWVzc2FnZSkgPyBKU09OLnN0cmluZ2lmeShtZXNzYWdlKSA6IG1lc3NhZ2UpO1xuICAgIGVycjIucmVzID0gcmVzO1xuICAgIGVycjIucmVxID0gcmVxO1xuICAgIHRocm93IGVycjI7XG4gIH1cblxuICBhc3luYyBhZnRlckZldGNoKGN0eCkge1xuICAgIGNvbnN0IHsgcmVzLCB0aHJvd0Vycm9yIH0gPSBjdHg7XG4gICAgaWYgKHJlcy5qc29uICYmIHJlcy5qc29uLmVycikge1xuICAgICAgYXdhaXQgdGhyb3dFcnJvcih7XG4gICAgICAgIC4uLmN0eCxcbiAgICAgICAgZXJyOiB7XG4gICAgICAgICAgdHlwZTogJ0NVU1RPTV9FUlJPUicsXG4gICAgICAgICAgLi4ucmVzLmpzb24uZXJyLFxuICAgICAgICB9LFxuICAgICAgfSk7XG4gICAgfVxuICAgIGlmIChyZXMuc3RhdHVzID49IDQwMCkge1xuICAgICAgY29uc3QgdHlwZSA9ICdSRVNfU1RBVFVTX0VSUk9SJztcbiAgICAgIGF3YWl0IHRocm93RXJyb3Ioe1xuICAgICAgICAuLi5jdHgsXG4gICAgICAgIGVycjoge1xuICAgICAgICAgIHR5cGUsXG4gICAgICAgICAgc3RhdHVzOiByZXMuc3RhdHVzLFxuICAgICAgICAgIHN0YXR1c1RleHQ6IHJlcy5zdGF0dXNUZXh0LFxuICAgICAgICAgIG1lc3NhZ2U6IGAke3R5cGV9OiAke3Jlcy5zdGF0dXN9ICR7cmVzLnN0YXR1c1RleHR9YCxcbiAgICAgICAgICAuLi4ocmVzLmpzb24gfHwge30pLFxuICAgICAgICB9LFxuICAgICAgfSk7XG4gICAgfVxuICAgIGlmIChyZXMudGV4dEVycikge1xuICAgICAgY29uc3QgdHlwZSA9ICdURVhUX1BBUlNFX0VSUk9SJztcbiAgICAgIGF3YWl0IGN0eC50aHJvd0Vycm9yKHtcbiAgICAgICAgLi4uY3R4LFxuICAgICAgICByZXMsXG4gICAgICAgIGVycjoge1xuICAgICAgICAgIHR5cGUsXG4gICAgICAgICAgbWVzc2FnZTogJ9Ce0YjQuNCx0LrQsCDQv9C10YDQtdC00LDRh9C4INC00LDQvdC90YvRhScsXG4gICAgICAgICAgZXJyOiByZXMudGV4dEVycixcbiAgICAgICAgfSxcbiAgICAgIH0pO1xuICAgIH1cbiAgICBpZiAocmVzLmpzb25FcnIpIHtcbiAgICAgIGNvbnN0IHR5cGUgPSAnSlNPTl9QQVJTRV9FUlJPUic7XG4gICAgICBhd2FpdCBjdHgudGhyb3dFcnJvcih7XG4gICAgICAgIC4uLmN0eCxcbiAgICAgICAgcmVzLFxuICAgICAgICBlcnI6IHtcbiAgICAgICAgICB0eXBlLFxuICAgICAgICAgIG1lc3NhZ2U6ICfQntGI0LjQsdC60LAg0YHQtdGA0LLQtdGA0LAnLFxuICAgICAgICAgIC8vIG1lc3NhZ2U6IHR5cGUsXG4gICAgICAgICAgZXJyOiByZXMuanNvbkVycixcbiAgICAgICAgfSxcbiAgICAgIH0pO1xuICAgIH1cbiAgICByZXR1cm4gcmVzLmpzb247XG4gIH1cblxuICBjcmVhdGVVcmwocGF0aCwgb3B0aW9ucyA9IHt9KSB7XG4gICAgaWYgKHBhdGguc3Vic3RyKDAsIDUpID09PSAnaHR0cDonIHx8IHBhdGguc3Vic3RyKDAsIDYpID09PSAn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QucmVjcmVhdGVTb2NrZXQocGF0aCwgb3B0aW9ucyk7XG4gICAgICAvLyBzb2NrZXQuZGlzY29ubmVjdCgpO1xuICAgICAgLy8gdGhpcy53cyhwYXRoLCBvcHRpb25zKTtcbiAgICB9KTtcbiAgfVxuXG4gIHdzKHBhdGggPSAnJywgb3B0aW9ucyA9IHt9KSB7XG4gICAgLy8gY29uc29sZS5sb2coJ2FwaS53cycsIHBhdGgpXG4gICAgY29uc3Qga2V5ID0gcGF0aCArIEpTT04uc3RyaW5naWZ5KG9wdGlvbnMpO1xuICAgIGlmICh0aGlzLndzQ29ubmVjdGlvbnNba2V5XSkgcmV0dXJuIHRoaXMud3NDb25uZWN0aW9uc1trZXldO1xuICAgIGlmICghdGhpcy53c0NvbmZpZykge1xuICAgICAgY29uc29sZS5lcnJvcign0JLRiyDQvdC1INC80L7QttC10YLQtSDQuNGB0L/QvtC70YzQt9C+0LLQsNGC0YwgYXBpLndzINCx0LXQtyDRgdC+0LrQtdGCINC60L7QvdGE0LjQs9C+0LInKTtcbiAgICAgIHJldHVybiBudWxsO1xuICAgIH1cbiAgICBjb25zdCBvcHRzID0gT2JqZWN0LmFzc2lnbih7fSwgdGhpcy53c0NvbmZpZyAmJiB0aGlzLndzQ29uZmlnLm9wdGlvbnMsIG9wdGlvbnMpO1xuICAgIC8vIGNvbnNvbGUubG9nKCdXUyBXUyBXUycsXG4gICAgLy8gICB7XG4gICAgLy8gICAgIHE6IHRoaXMud3NDb25maWcgJiYgdGhpcy53c0NvbmZpZy5vcHRpb25zLFxuICAgIC8vICAgICB3OiBvcHRpb25zLFxuICAgIC8vICAgICBlOiBvcHRzLFxuICAgIC8vICAgICByOiBPYmplY3QuYXNzaWduKHt9LCB0aGlzLndzQ29uZmlnICYmIHRoaXMud3NDb25maWcub3B0aW9ucywgb3B0aW9ucylcbiAgICAvLyAgIH1cbiAgICAvLyApO1xuICAgIC8vIGNvbnNvbGUubG9nKG9wdHMucXVlcnksIG9wdHMucXVlcnkudG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MiksXG4gICAgICB7XG4gICAgICAgIC4uLnRoaXMud3NDb25maWcub3B0aW9ucyxcbiAgICAgICAgLi4ucGFyYW1zLFxuICAgICAgfSxcbiAgICApO1xuICAgIHJldHVybiByZXM7XG4gIH1cblxufVxuIl19
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uL3NyYy9hcGlxdWVyeS5qcyJdLCJuYW1lcyI6WyJGRVRDSF9QQVJBTVMiLCJpb01vY2siLCJtb2NrIiwiTWFuYWdlciIsIlNvY2tldCIsImNvbm5lY3Rpb24iLCJldmVudHMiLCJvbiIsInBhcmFtcyIsInB1c2giLCJ1c2UiLCJkaXNjb25uZWN0IiwicmVjcmVhdGVTb2NrZXQiLCJmb3JFYWNoIiwiZXZlbnQiLCJuYW1lIiwiQXBpQ2xpZW50IiwidGhyb3dFcnJvciIsImVyciIsInJlcyIsInJlcSIsInNob3dFcnJvciIsImxvZyIsInN0ciIsIkpTT04iLCJzdHJpbmdpZnkiLCJqc29uIiwiZXJyb3IiLCJtZXNzYWdlIiwiZXJyMiIsIkVycm9yIiwiaW8iLCJyb290IiwiYmFzZSIsInVybCIsIndzQ29uZmlnIiwid3MiLCJ3c0Nvbm5lY3Rpb25zIiwiYXV0aFRva2VuIiwid3NSZWNvbm5lY3QiLCJjdHgiLCJ0eXBlIiwic3RhdHVzIiwic3RhdHVzVGV4dCIsInRleHRFcnIiLCJqc29uRXJyIiwicGF0aCIsIm9wdGlvbnMiLCJzdWJzdHIiLCJwb3J0IiwibGVuZ3RoIiwic2VhcmNoIiwicmVwbGFjZSIsImFycmF5IiwibWFwIiwiYSIsImZpbHRlciIsImkiLCJqb2luIiwicXMiLCJpbmRleE9mIiwiY29uc3RydWN0b3IiLCJPYmplY3QiLCJhc3NpZ24iLCJib2R5IiwiZGF0YSIsImhlYWRlcnMiLCJBY2NlcHQiLCJfYm9keSIsImluY2x1ZGVzIiwiZm9ybSIsImtleXMiLCJr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Mil9XG4gIGpzb246XG4ke0pTT04uc3RyaW5naWZ5KHJlcy5qc29uLCBudWxsLCAyKX1cbj09PT09PT09PT09PT09XFxcbmA7XG4gICAgICB0aGlzLmxvZy5lcnJvcihzdHIpO1xuICAgIH1cbiAgICBjb25zdCBtZXNzYWdlID0gZXJyICYmIGVyci5tZXNzYWdlIHx8IGVycjtcbiAgICBjb25zdCBlcnIyID0gbmV3IEVycm9yKGlzUGxhaW5PYmplY3QobWVzc2FnZSkgPyBKU09OLnN0cmluZ2lmeShtZXNzYWdlKSA6IG1lc3NhZ2UpO1xuICAgIGVycjIucmVzID0gcmVzO1xuICAgIGVycjIucmVxID0gcmVxO1xuICAgIHRocm93IGVycjI7XG4gIH1cblxuICBhc3luYyBhZnRlckZldGNoKGN0eCkge1xuICAgIGNvbnN0IHsgcmVzLCB0aHJvd0Vycm9yIH0gPSBjdHg7XG4gICAgaWYgKHJlcy5qc29uICYmIHJlcy5qc29uLmVycikge1xuICAgICAgYXdhaXQgdGhyb3dFcnJvcih7XG4gICAgICAgIC4uLmN0eCxcbiAgICAgICAgZXJyOiB7XG4gICAgICAgICAgdHlwZTogJ0NVU1RPTV9FUlJPUicsXG4gICAgICAgICAgLi4ucmVzLmpzb24uZXJyLFxuICAgICAgICB9LFxuICAgICAgfSk7XG4gICAgfVxuICAgIGlmIChyZXMuc3RhdHVzID49IDQwMCkge1xuICAgICAgY29uc3QgdHlwZSA9ICdSRVNfU1RBVFVTX0VSUk9SJztcbiAgICAgIGF3YWl0IHRocm93RXJyb3Ioe1xuICAgICAgICAuLi5jdHgsXG4gICAgICAgIGVycjoge1xuICAgICAgICAgIHR5cGUsXG4gICAgICAgICAgc3RhdHVzOiByZXMuc3RhdHVzLFxuICAgICAgICAgIHN0YXR1c1RleHQ6IHJlcy5zdGF0dXNUZXh0LFxuICAgICAgICAgIG1lc3NhZ2U6IGAke3R5cGV9OiAke3Jlcy5zdGF0dXN9ICR7cmVzLnN0YXR1c1RleHR9YCxcbiAgICAgICAgICAuLi4ocmVzLmpzb24gfHwge30pLFxuICAgICAgICB9LFxuICAgICAgfSk7XG4gICAgfVxuICAgIGlmIChyZXMudGV4dEVycikge1xuICAgICAgY29uc3QgdHlwZSA9ICdURVhUX1BBUlNFX0VSUk9SJztcbiAgICAgIGF3YWl0IGN0eC50aHJvd0Vycm9yKHtcbiAgICAgICAgLi4uY3R4LFxuICAgICAgICByZXMsXG4gICAgICAgIGVycjoge1xuICAgICAgICAgIHR5cGUsXG4gICAgICAgICAgbWVzc2FnZTogJ9Ce0YjQuNCx0LrQsCDQv9C10YDQtdC00LDRh9C4INC00LDQvdC90YvRhScsXG4gICAgICAgICAgZXJyOiByZXMudGV4dEVycixcbiAgICAgICAgfSxcbiAgICAgIH0pO1xuICAgIH1cbiAgICBpZiAocmVzLmpzb25FcnIpIHtcbiAgICAgIGNvbnN0IHR5cGUgPSAnSlNPTl9QQVJTRV9FUlJPUic7XG4gICAgICBhd2FpdCBjdHgudGhyb3dFcnJvcih7XG4gICAgICAgIC4uLmN0eCxcbiAgICAgICAgcmVzLFxuICAgICAgICBlcnI6IHtcbiAgICAgICAgICB0eXBlLFxuICAgICAgICAgIG1lc3NhZ2U6ICfQntGI0LjQsdC60LAg0YHQtdGA0LLQtdGA0LAnLFxuICAgICAgICAgIC8vIG1lc3NhZ2U6IHR5cGUsXG4gICAgICAgICAgZXJyOiByZXMuanNvbkVycixcbiAgICAgICAgfSxcbiAgICAgIH0pO1xuICAgIH1cbiAgICByZXR1cm4gcmVzLmpzb247XG4gIH1cblxuICBjcmVhdGVVcmwocGF0aCwgb3B0aW9ucyA9IHt9KSB7XG4gICAgaWYgKHBhdGguc3Vic3RyKDAsIDUpID09PSAnaHR0cDonIHx8IHBhdGguc3Vic3RyKDAsIDYpID09PSAnaHR0cHM6Jykge1xuICAgICAgcmV0dXJuIHBhdGg7XG4gICAgfVxuICAgIGxldCB1cmwgPSBvcHRpb25zLnVybCB8fCB0aGlzLnVybCB8fCAnLyc7XG4gICAgY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gICAgLy8gdGhpcy53cyhwYXRoLCBvcHRpb25zKTtcbiAgICB9KTtcbiAgfVxuXG4gIHdzKHBhdGggPSAnJywgb3B0aW9ucyA9IHt9KSB7XG4gICAgLy8gY29uc29sZS5sb2coJ2FwaS53cycsIHBhdGgpXG4gICAgY29uc3Qga2V5ID0gcGF0aCArIEpTT04uc3RyaW5naWZ5KG9wdGlvbnMpO1xuICAgIGlmICh0aGlzLndzQ29ubmVjdGlvbnNba2V5XSkgcmV0dXJuIHRoaXMud3NDb25uZWN0aW9uc1trZXldO1xuICAgIGlmICghdGhpcy53c0NvbmZpZykge1xuICAgICAgY29uc29sZS5lcnJvcign0JLRiyDQvdC1INC80L7QttC10YLQtSDQuNGB0L/QvtC70YzQt9C+0LLQsNGC0YwgYXBpLndzINCx0LXQtyDRgdC+0LrQtdGCINC60L7QvdGE0LjQs9C+0LInKTtcbiAgICAgIHJldHVybiBudWxsO1xuICAgIH1cbiAgICBjb25zdCBvcHRzID0gT2JqZWN0LmFzc2lnbih7fSwgdGhpcy53c0NvbmZpZyAmJiB0aGlzLndzQ29uZmlnLm9wdGlvbnMsIG9wdGlvbnMpO1xuICAgIC8vIGNvbnNvbGUubG9nKCdXUyBXUyBXUycsXG4gICAgLy8gICB7XG4gICAgLy8gICAgIHE6IHRoaXMud3NDb25maWcgJiYgdGhpcy53c0NvbmZpZy5vcHRpb25zLFxuICAgIC8vICAgICB3OiBvcHRpb25zLFxuICAgIC8vICAgICBlOiBvcHRzLFxuICAgIC8vICAgICByOiBPYmplY3QuYXNzaWduKHt9LCB0aGlzLndzQ29uZmlnICYmIHRoaXMud3NDb25maWcub3B0aW9ucywgb3B0aW9ucylcbiAgICAvLyAgIH1cbiAgICAvLyApO1xuICAgIC8vIGNvbnNvbGUubG9nKG9wdHMucXVlcnksIG9wdHMucXVlcnkudG9rZW4sIHRoaXMuYXV0aFRva2VuKTtcbiAgICBpZiAoISh0aGlzLndzQ29uZmlnICYmIHRoaXMud3NDb25maWcudG9rZW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gICAgfSxcbiAgICApO1xuICAgIHJldHVybiByZXM7XG4gIH1cblxufVxuIl19
{
"name": "apiquery",
"version": "0.1.19",
"version": "0.1.20",
"description": "http + websockets api client for Web, Node.js and React Native",

@@ -5,0 +5,0 @@ "repository": {

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