Created
November 30, 2015 09:46
-
-
Save hhanesand/b809d6f1d438174e2d91 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
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