buildBodyType method

String? buildBodyType(
  1. String? body
)

Implementation

String? buildBodyType(String? body) {
  if (this.bodyType == null || body == null) return null;

  var bodyType = this.bodyType!.trim();
  if (bodyType.isEmpty) return null;

  return MimeType.parseAsString(bodyType, bodyType);
}