You've got two functions that each return a jQuery Promise object, and a function that waits for both of them and then handles each result separately. Seems to me like it would be clearer and more efficient to make each Promise handle its own data, so that each callback fires as soon as possible. It also brings the AJAX call and the success callback closer together in the code, so that the logic is easier to understand.