docs: private String getMediaType(String contentType) {
          if (contentType == null) {
              return null;
          }
          String result = contentType.toLowerCase(Locale.ENGLISH);
          int firstSemiColonIndex = result.indexOf(';');
          if (firstSemiColonIndex > -1) {
              result = result.substring(0, firstSemiColonIndex);
          }
          result = result.trim();
          return result;
      }