Passed forward the error response in a ajax call failure

The error response from server was not passed forward to repositories.