Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

app-notify

Package Overview
Dependencies
Maintainers
1
Versions
15
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

app-notify - npm Package Compare versions

Comparing version 2.0.2 to 2.1.0

4

gulpfile.js

@@ -1,3 +0,3 @@

var gulp = require('gulp');
var mocha = require('gulp-mocha');
const gulp = require('gulp');
const mocha = require('gulp-mocha');

@@ -4,0 +4,0 @@ gulp.task('default', ['test']);

@@ -1,6 +0,6 @@

var Sms = require('./lib/sms');
var Email = require('./lib/email');
var _ = require('lodash');
var async = require('async');
var q = require('q');
const Sms = require('./lib/sms');
const Email = require('./lib/email');
const _ = require('lodash');
const async = require('async');
const q = require('q');

@@ -17,3 +17,3 @@ function Notify(cfg){

var notify = {
const notify = {
respondWithError: function(err, method){

@@ -38,3 +38,3 @@ if ( typeof method === 'function' ) {

var method = !callback ? q.defer() : callback;
const method = !callback ? q.defer() : callback;

@@ -41,0 +41,0 @@ async.parallel([

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

var nodemailer = require('nodemailer');
var q = require('q');
var _ = require('lodash');
const nodemailer = require('nodemailer');
const q = require('q');
const _ = require('lodash');

@@ -13,3 +13,3 @@ function Email(cfg){

var email = {
const email = {
respondWithError: function(err, method){

@@ -32,4 +32,3 @@ if ( typeof method === 'function' ) {

send: function (opts, cb){
var cfg = this.cfg;
var method = !cb ? q.defer() : cb;
const method = !cb ? q.defer() : cb;

@@ -50,6 +49,6 @@ opts = _.merge(this.cfg, opts);

var user = opts.smtp.user;
var pass = opts.smtp.pass;
var host = opts.smtp.host;
var port = opts.smtp.port;
const user = opts.smtp.user;
const pass = opts.smtp.pass;
const host = opts.smtp.host;
const port = opts.smtp.port;

@@ -70,3 +69,3 @@ if ( !user || !pass || !host || !port ) {

var transporter = nodemailer.createTransport({
const transporter = nodemailer.createTransport({
host: host,

@@ -81,3 +80,3 @@ port: port,

var mailOptions = {
const mailOptions = {
from: opts.email.from,

@@ -84,0 +83,0 @@ to: opts.email.to,

@@ -1,3 +0,3 @@

var q = require('q');
var _ = require('lodash');
const q = require('q');
const _ = require('lodash');

@@ -12,3 +12,3 @@ function Sms(cfg){

var sms = {
const sms = {
respondWithError: function respondWithError(err, method){

@@ -31,4 +31,3 @@ if ( typeof method === 'function' ) {

send: function send(opts, cb){
var cfg = this.cfg;
var method = !cb ? q.defer() : cb;
const method = !cb ? q.defer() : cb;

@@ -42,4 +41,4 @@ opts = _.merge(this.cfg, opts);

var sid = opts.sms.sid;
var auth = opts.sms.auth;
const sid = opts.sms.sid;
const auth = opts.sms.auth;

@@ -56,3 +55,3 @@ //check for required auth

var client = require('twilio')(sid, auth);
const client = require('twilio')(sid, auth);

@@ -59,0 +58,0 @@ client.sendMessage({

{
"name": "app-notify",
"version": "2.0.2",
"version": "2.1.0",
"description": "Send SMS and email notifications from within your node.js app",

@@ -23,19 +23,18 @@ "main": "index.js",

"license": "ISC",
"bugs": {
"url": "https://github.com/chovy/app-notify/issues"
},
"bugs": {},
"url": "https://github.com/chovy/app-notify/issues",
"homepage": "https://github.com/chovy/app-notify",
"dependencies": {
"async": "^0.9.0",
"lodash": "^2.4.1",
"nodemailer": "^1.3.0",
"q": "^1.1.2",
"twilio": "^1.10.0"
"async": "^3.1.0",
"lodash": "^4.17.15",
"nodemailer": "^6.3.0",
"q": "^1.5.1",
"twilio": "^3.35.1"
},
"devDependencies": {
"chai": "^1.10.0",
"gulp": "^3.8.10",
"gulp-mocha": "^2.0.0",
"mocha": "^2.0.1"
"chai": "^4.2.0",
"gulp": "^3.x",
"gulp-mocha": "^7.0.2",
"mocha": "^6.2.1"
}
}
app-notify
==========
Send SMS and email notifications from within your node.js app
Send Twilio SMS and SMTP email notifications from within your node.js app

@@ -13,5 +13,5 @@ # install

```javascript
var Notify = require('app-notify');
var cfg = {...};
var notify = new Notify(cfg);
const Notify = require('app-notify');
const cfg = {...};
const notify = new Notify(cfg);
```

@@ -24,3 +24,3 @@

```javascript
var cfg = {};
const cfg = {};

@@ -41,4 +41,4 @@ //setup smtp server

var Notify = require('app-notify');
var notify = new Notify(cfg);
const Notify = require('app-notify');
const notify = new Notify(cfg);

@@ -61,3 +61,3 @@ //send an email

```javascript
var cfg = {};
const cfg = {};

@@ -72,4 +72,4 @@ //setup sms configuration

var Notify = require('app-notify');
var notify = new Notify(cfg);
const Notify = require('app-notify');
const notify = new Notify(cfg);

@@ -90,3 +90,3 @@ notify.sms({

```javascript
var cfg = {};
const cfg = {};

@@ -107,4 +107,4 @@ //setup smtp server

var Notify = require('app-notify');
var notify = new Notify(cfg);
const Notify = require('app-notify');
const notify = new Notify(cfg);

@@ -134,2 +134,2 @@ //sends both

gulp test
```
```

@@ -1,12 +0,12 @@

var Notify = require('../../index');
var expect = require('chai').expect;
var config = require('../config');
var _ = require('lodash');
const Notify = require('../../index');
const expect = require('chai').expect;
const config = require('../config');
const _ = require('lodash');
describe('All', function(){
var notify;
let notify;
describe('send', function(){
beforeEach(function() {
var cfg = _.cloneDeep(config);
const cfg = _.cloneDeep(config);
notify = new Notify(cfg);

@@ -13,0 +13,0 @@ });

@@ -1,12 +0,12 @@

var Notify = require('../../index');
var expect = require('chai').expect;
var config = require('./../config');
var _ = require('lodash');
const Notify = require('../../index');
const expect = require('chai').expect;
const config = require('./../config');
const _ = require('lodash');
describe('Email', function(){
describe('email', function(){
var notify;
let notify;
beforeEach(function() {
var cfg = _.cloneDeep(config);
const cfg = _.cloneDeep(config);
notify = new Notify(cfg);

@@ -13,0 +13,0 @@ });

@@ -1,11 +0,11 @@

var Notify = require('../../index');
var expect = require('chai').expect;
var config = require('./../config');
var _ = require('lodash');
const Notify = require('../../index');
const expect = require('chai').expect;
const config = require('./../config');
const _ = require('lodash');
describe('SMS', function(){
var notify;
let notify;
beforeEach(function() {
var cfg = _.cloneDeep(config);
const cfg = _.cloneDeep(config);
notify = new Notify(cfg);

@@ -12,0 +12,0 @@ });

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