map method

  1. @override
Resource<R> map(
  1. Either<Exception, R> data
)
override

Implementation

@override
Resource<R> map(Either<Exception, R> data) {
  return data.match(
      (l) => Resource.error(failure: l), (r) => Resource.success(r));
}