After reading your comment regarding Nikolai Rouche's answer (which is correct), it is obvious that the reason for the failure is that you do not check that response.products contains any products at all before referring to its first element. Still, it should not happen that you do not receive the correct product in the answer (especially if it always worked and the product of the application was accepted with the application), but you did not cope with this matter, and this is what causes the accident.
source share