export class extends Error export class UserInfoError extends Error { readonly name = 'UserInfoError' ; constructor ( readonly error ) { super ( 'The resource server returned an error. Impossible to access the user\'s information.\n' + JSON . stringify ( error , null , 2 ) ) ; } }