closeSurvey method

void closeSurvey({
  1. required BuildContext context,
  2. StepResult? stepResult,
})

Implementation

void closeSurvey({
  required BuildContext context,
  StepResult? stepResult,
}) {
  if (onCloseSurvey != null) {
    onCloseSurvey!(context, stepResult);
    return;
  }
  SurveyStateProvider.of(context).onEvent(
    CloseSurvey(
      stepResult,
    ),
  );
}