Rename catch-all outcome

This commit is contained in:
Sipke Schoorstra 2023-03-09 11:23:35 +01:00
parent c5f35c81fc
commit ba02b80fb0
2 changed files with 2 additions and 2 deletions

View file

@ -20,7 +20,7 @@ export class FlowHttpRequestPortProvider implements PortProvider {
const statusCodesJson = (expectedStatusCodes.expression as JsonExpression).value;
const statusCodes = JSON.parse(statusCodesJson) as Array<string>;
const catchAllPort = {name: 'Catch all', displayName: 'Catch all', mode: PortMode.Port};
const catchAllPort = {name: 'Unmatched status code', displayName: 'Unmatched status code', mode: PortMode.Port};
const outcomes = [...statusCodes.map(x => ({name: x.toString(), displayName: x.toString(), mode: PortMode.Port})), catchAllPort];
return outcomes;

View file

@ -33,7 +33,7 @@ public class FlowSendHttpRequest : SendHttpRequestBase
var expectedStatusCodes = ExpectedStatusCodes.TryGet(context) ?? new List<int>(0);
var statusCode = (int)response.StatusCode;
var hasMatchingStatusCode = expectedStatusCodes.Contains(statusCode);
var outcome = hasMatchingStatusCode ? statusCode.ToString() : "Catch all";
var outcome = hasMatchingStatusCode ? statusCode.ToString() : "Unmatched status code";
await context.CompleteActivityWithOutcomesAsync(outcome);
}