Update Stencil flow switch port provider with default case

This commit is contained in:
Sipke Schoorstra 2023-10-19 18:34:14 +02:00
parent 08d91d1852
commit f0047e63cb

View file

@ -14,7 +14,9 @@ export class FlowSwitchPortProvider implements PortProvider {
return [];
const cases = activity.cases ?? [];
return cases.map(x => ({name: x.label, displayName: x.label, type: PortType.Flow}));
const ports = cases.map(x => ({name: x.label, displayName: x.label, type: PortType.Flow}));
const defaultPort: Port = {name: 'Default', displayName: 'Default', type: PortType.Flow};
return [...ports, defaultPort];
}
resolvePort(portName: string, context: PortProviderContext): Activity | Array<Activity> {