We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent f8ccb4a commit 8e6263eCopy full SHA for 8e6263e
src/PostHog/Library/HttpClientExtensions.cs
@@ -45,11 +45,17 @@ public static async Task EnsureSuccessfulApiCall(
45
this HttpResponseMessage response,
46
CancellationToken cancellationToken)
47
{
48
- // TODO: Is there any error status codes that we should allow the exception to propagate here?
49
if (response.IsSuccessStatusCode)
50
51
return;
52
}
+
53
+ if (response.StatusCode == HttpStatusCode.NotFound)
54
+ {
55
+ // Allow 404 exception to propagate up.
56
+ response.EnsureSuccessStatusCode();
57
+ }
58
59
var (error, exception) = await ReadApiErrorResultAsync();
60
61
throw response.StatusCode switch
0 commit comments