undoWhiteBoard method

  1. @override
Future<void> undoWhiteBoard()
override

Implementation

@override
Future<void> undoWhiteBoard() async {
  if (_localPaints.isEmpty || roomId == null) return;

  final undoModel = _localPaints.last;
  _localPaints.removeLast();

  _socketEmiter.updateWhiteBoard(
    roomId!,
    DrawActionEnum.updateRemove.action,
    undoModel,
  );
  _emitWhiteBoard();
}