Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- var r = {};
- db.query("SELECT .. #1")
- .addCallback(function(result1) {
- r.result1 = result1;
- return db.query("SELECT .. #2");
- })
- .addCallback(function(result2) {
- r.result2 = result2;
- return templates.load("file-name");
- })
- .addCallback(function(template) {
- r.template = template;
- r // now has everything
- })
Add Comment
Please, Sign In to add comment