Change the way json failure is dealt with