Ishi Systems Interview Question

How to handle error in ajax response centrally.