handle null endpoint in error message