Recognize 'unauthorized' errors in ajax requests.