runFunction method

void runFunction(
  1. BuildContext context,
  2. EmitNewStateAction action,
  3. Map<ID, Variable> conStringVars,
  4. dynamic inputValue,
)

Implementation

void runFunction(
  BuildContext context,
  EmitNewStateAction action,
  Map<ID, Variable> conStringVars,
  dynamic inputValue,
) {
  try {
    _emit(context, action, conStringVars, inputValue);
  } catch (e) {
    context.read<AppLogsCubit>().onNewLog(
          EditorLogEntity(
            id: _uuid.v1(),
            content: e.toString(),
            createdAt: DateTime.now(),
          ),
        );
  }
  return;
}