I have the following code:
(saveData())
.pipe(function(data){return sendhandovermail($('#editperson_id').val());})
.pipe(function(data){setHistory(_eciId,'4','12',true);})
.pipe(function(data){window.location.href = 'input.cfm?m=4&id=45';})
.fail(function(data){$('##msgDialogDetail').html("Error while saving. Please contact bla@blup.com");});
The code works (no errors) but... I was told .pipe() method will do all ajax calls one after the other. IF A returns, B will start. Though when I run it, it's not the case. Am I understanding it wrong, or how should I write this chain to have it execute one after the other?