Socket
Socket
Sign inDemoInstall

ispapi-apiconnector

Package Overview
Dependencies
0
Maintainers
1
Versions
51
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 3.5.5 to 3.5.6

26

index.js

@@ -331,2 +331,28 @@ /*

};
/**
* returns a default response template as parsed js object hash
* @param {String} p_tplid the id of the template to return
* @param {Boolean} p_parse flag to toggle the returned format. true: parsed, otherwise: unparsed
* @return {Object|String|Boolean} default response template of false if not found
*/
Response.getTemplate = function (p_tplid, p_parse) {
if (responses[p_tplid])
if (p_parse)
return Response.parse(responses[p_tplid]);
else
return responses[p_tplid];
return false;
};
/**
* check if the given response matches a default response template
* @param {Object} p_r given response
* @param {String} p_tplid given default template id
* @return {Boolean} the check result
*/
Response.isTemplateMatch = function (p_r, p_tplid) {
var tpl = Response.getTemplate(p_tplid, true);
if (tpl && p_r.CODE === tpl.CODE && p_r.DESCRIPTION === tpl.DESCRIPTION)
return true;
return false;
};

@@ -333,0 +359,0 @@ Response.pagerRegexp = /^(TOTAL|FIRST|LAST|LIMIT|COUNT)$/;

2

package.json
{
"name": "ispapi-apiconnector",
"description": "1API API Connector for node.js",
"version": "3.5.5",
"version": "3.5.6",
"author": {

@@ -6,0 +6,0 @@ "name": "Kai Schwarz",

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