add a cause to different error types