Simplify String concatenation

This commit is contained in:
stsypanov
2019-03-14 12:37:08 +02:00
committed by Juergen Hoeller
parent 9d2e7ced89
commit 29f382b04e
6 changed files with 19 additions and 32 deletions

View File

@@ -92,12 +92,10 @@ abstract class AbstractMediaTypeExpression implements MediaTypeExpression, Compa
@Override
public String toString() {
StringBuilder builder = new StringBuilder();
if (this.isNegated) {
builder.append('!');
return '!' + this.mediaType.toString();
}
builder.append(this.mediaType.toString());
return builder.toString();
return this.mediaType.toString();
}
}