chain function

PollStrategy chain(
  1. List<PollStrategy> strategies
)

Implementation

PollStrategy chain(List<PollStrategy> strategies) {
  return (
    Principal canisterId,
    RequestId requestId,
    String status,
  ) async {
    for (var a in strategies) {
      await a(canisterId, requestId, status);
    }
  };
}