Example showing async.waterfall which functions semantically the same as promises.
<script src="http://cdnjs.cloudflare.com/ajax/libs/async/1.22/async.min.js"></script>
<script>
// waterfall wrapper to try/catch each method in a waterfall
var catchWaterfall = function(arr, cb) {
var calls = [];
arr.forEach(function(val) {