execute method

  1. @override
Future execute(
  1. BuildContext context,
  2. ScopeManager scopeManager
)
override

TODO: each Action does all the execution in here use DataContext to eval properties. ScopeManager should be refactored so it contains the update data context (its DataContext might not have the latest data)

Implementation

@override
Future<dynamic> execute(
    BuildContext context, ScopeManager scopeManager) async {
  try {
    await GetIt.I<FaceCameraManager>()
        .openFaceCamera(context, this, scopeManager);
  } catch (e) {
    if (onError != null) {
      await ScreenController().executeAction(context, onError!,
          event: EnsembleEvent(null, error: e.toString()));
    }
  }
}