Fix for handling error response from authentication provider

Fix for #16 and #15