cancel method

  1. @override
void cancel([
  1. dynamic reason
])
override

Cancels the current request (upload or download of file).

Implementation

@override
void cancel([dynamic reason]) {
  _cancelToken?.cancel(reason);
  _cancelToken = null;
}