Socket
Socket
Sign inDemoInstall

twilio

Package Overview
Dependencies
Maintainers
1
Versions
301
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

twilio - npm Package Compare versions

Comparing version 1.1.0 to 1.1.1

20

lib/Capability.js
var jwt = require('jwt-simple'),
qs = require('querystring');
function Capability(accountSid, authToken) {
this.accountSid = accountSid;
this.authToken = authToken;
function Capability(sid, tkn) {
// Initialize from environment variables, if present
if (!sid || !tkn) {
if (process.env.TWILIO_ACCOUNT_SID && process.env.TWILIO_AUTH_TOKEN) {
this.accountSid = process.env.TWILIO_ACCOUNT_SID;
this.authToken = process.env.TWILIO_AUTH_TOKEN;
}
else {
throw 'Capability requires an Account SID and Auth Token set explicitly ' +
'or via the TWILIO_ACCOUNT_SID and TWILIO_AUTH_TOKEN environment variables';
}
}
else {
//if auth token/SID passed in manually, trim spaces
this.accountSid = sid.replace(/ /g,'');
this.authToken = tkn.replace(/ /g,'');
}
this.capabilities = [];

@@ -8,0 +22,0 @@ }

2

package.json
{
"name":"twilio",
"description":"A Twilio helper library",
"version":"1.1.0",
"version":"1.1.1",
"author":"Kevin Whinnery <kevin.whinnery@gmail.com>",

@@ -6,0 +6,0 @@ "contributors":[

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