Last active
July 13, 2016 02:58
-
-
Save wallacyyy/ddb722d15310b1905c06d22b998c5e01 to your computer and use it in GitHub Desktop.
2016-07-11
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const RSVP = require('./rsvp') | |
const ID = function () { | |
return Math.random().toString(36).substr(2, 9) | |
} | |
const invites = [ | |
{ | |
email: 'name@gmail.com', | |
name: 'Name', | |
confirmed: false, | |
url: ID() | |
}, | |
{ | |
email: 'anothername@gmail.com', | |
name: 'Another Name', | |
confirmed: false, | |
url: ID() | |
} | |
] | |
invites.forEach(function (invite) { | |
RSVP.create(invite).then(function (created) { | |
console.log(created) | |
}).catch(function (err) { | |
console.log(err) | |
}) | |
}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment