Skip to content

Instantly share code, notes, and snippets.

@hhanesand
Created November 30, 2015 09:46
Show Gist options
  • Save hhanesand/b809d6f1d438174e2d91 to your computer and use it in GitHub Desktop.
Save hhanesand/b809d6f1d438174e2d91 to your computer and use it in GitHub Desktop.
function saveAllWithPromise(items) {
var saveAllPromise = new Parse.Promise();
Parse.Object.saveAll(items, {
success: function (items) {
saveAllPromise.resolve(items);
}, error: function (error) {
saveAllPromise.reject(error);
}
});
return saveAllPromise;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment