We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent b9b603b commit 9658c3eCopy full SHA for 9658c3e
UnitTestProject1/Tests/SiteTokenTests.cs
@@ -79,7 +79,7 @@ public async Task BadTokenTest(string endpointUrl, string sandboxPageTitle)
79
// This should cause token cache invalidation.
80
await page.EditAsync(new WikiPageEditOptions { Content = page.Content!, Summary = "Make an empty update.", Minor = true });
81
}
82
- catch (OperationFailedException ex) when (ex.ErrorCode == "globalblocking-blockedtext-range")
+ catch (OperationFailedException ex) when (ex.ErrorCode is "blocked" or "globalblocking-blockedtext-range")
83
{
84
// wikimedia-globalblocking-ipblocked-range
85
Output.WriteLine("UpdateContentAsync fails due to IP block: " + ex);
0 commit comments