Azure and the “Cannot read property ‘isSuccessful’ of null” error