Gestire errore 401 su richiesta ajax con angularjs

From http://stackoverflow.com/questions/11971213/error-401-handling-with-angularjs