I have an ajax call inside a loop and I want to detect the last time the ajax call is fired in the loop:
for ( var i = 0; i < diff.length ; i++ ) { ...