File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
spring-core/src/main/java/org/springframework/util Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -219,7 +219,7 @@ private static MimeType parseMimeTypeInternal(String mimeType) {
219
219
throw new InvalidMimeTypeException (mimeType , "does not contain subtype after '/'" );
220
220
}
221
221
String type = fullType .substring (0 , subIndex );
222
- String subtype = fullType .substring (subIndex + 1 , fullType . length () );
222
+ String subtype = fullType .substring (subIndex + 1 );
223
223
if (MimeType .WILDCARD_TYPE .equals (type ) && !MimeType .WILDCARD_TYPE .equals (subtype )) {
224
224
throw new InvalidMimeTypeException (mimeType , "wildcard type is legal only in '*/*' (all mime types)" );
225
225
}
@@ -248,7 +248,7 @@ else if (ch == '"') {
248
248
int eqIndex = parameter .indexOf ('=' );
249
249
if (eqIndex >= 0 ) {
250
250
String attribute = parameter .substring (0 , eqIndex ).trim ();
251
- String value = parameter .substring (eqIndex + 1 , parameter . length () ).trim ();
251
+ String value = parameter .substring (eqIndex + 1 ).trim ();
252
252
parameters .put (attribute , value );
253
253
}
254
254
}
You can’t perform that action at this time.
0 commit comments