patch method

Future<Response> patch (
  1. dynamic url,
  2. {Map<String, String> headers,
  3. dynamic body,
  4. Encoding encoding}
)
override

Implementation

Future<Response> patch(url,
    {Map<String, String> headers, body, Encoding encoding}) async {
  if (_onlyGET) {
    return _transporter.patch(url,
        headers: headers, body: body, encoding: encoding);
  }
  final String id = _id(Method.PATCH, url, headers, body);
  Response response = _get(id);
  if (response == null) {
    response = await _transporter.patch(url,
        headers: headers, body: body, encoding: encoding);
    _put(id, response);
  }
  return response;
}