From f87b5ee3262d281ba650762b9a5a00332b932170 Mon Sep 17 00:00:00 2001 From: Sam Brannen <104798+sbrannen@users.noreply.github.com> Date: Mon, 23 Feb 2026 17:24:13 +0100 Subject: [PATCH] Polish contribution See gh-36367 (cherry picked from commit b1cb9c50521bab3c056e96534dcd99d78a06ea47) --- .../expressionsoperatorsoverloaded/ListConcatenation.java | 5 +++-- .../expressionsoperatorsoverloaded/ListConcatenation.kt | 8 +++++--- 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/framework-docs/src/main/java/org/springframework/docs/core/expressions/languageref/expressionsoperatorsoverloaded/ListConcatenation.java b/framework-docs/src/main/java/org/springframework/docs/core/expressions/languageref/expressionsoperatorsoverloaded/ListConcatenation.java index 6bd1ea62e2a..c17c3a82ef3 100644 --- a/framework-docs/src/main/java/org/springframework/docs/core/expressions/languageref/expressionsoperatorsoverloaded/ListConcatenation.java +++ b/framework-docs/src/main/java/org/springframework/docs/core/expressions/languageref/expressionsoperatorsoverloaded/ListConcatenation.java @@ -1,5 +1,5 @@ /* - * Copyright 2026-present the original author or authors. + * Copyright 2002-present the original author or authors. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -26,7 +26,7 @@ public class ListConcatenation implements OperatorOverloader { @Override public boolean overridesOperation(Operation operation, Object left, Object right) { - return operation == Operation.ADD && left instanceof List && right instanceof List; + return (operation == Operation.ADD && left instanceof List && right instanceof List); } @Override @@ -43,4 +43,5 @@ public class ListConcatenation implements OperatorOverloader { "No overload for operation %s and operands [%s] and [%s]" .formatted(operation, left, right)); } + } diff --git a/framework-docs/src/main/kotlin/org/springframework/docs/core/expressions/languageref/expressionsoperatorsoverloaded/ListConcatenation.kt b/framework-docs/src/main/kotlin/org/springframework/docs/core/expressions/languageref/expressionsoperatorsoverloaded/ListConcatenation.kt index 49e113823d0..fbe430ddd86 100644 --- a/framework-docs/src/main/kotlin/org/springframework/docs/core/expressions/languageref/expressionsoperatorsoverloaded/ListConcatenation.kt +++ b/framework-docs/src/main/kotlin/org/springframework/docs/core/expressions/languageref/expressionsoperatorsoverloaded/ListConcatenation.kt @@ -1,5 +1,5 @@ /* - * Copyright 2026-present the original author or authors. + * Copyright 2002-present the original author or authors. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -30,6 +30,8 @@ class ListConcatenation: OperatorOverloader { return left + right } - throw UnsupportedOperationException("No overload for operation $operation and operands [$left] and [$right]") + throw UnsupportedOperationException( + "No overload for operation $operation and operands [$left] and [$right]") } -} \ No newline at end of file + +}