furqaankhan commented on code in PR #2184:
URL: https://github.com/apache/sedona/pull/2184#discussion_r2237999123
##########
common/src/main/java/org/apache/sedona/common/Functions.java:
##########
@@ -386,12 +388,16 @@ else if
(singleParam[0].equalsIgnoreCase(listBufferParameters[3])
// Set side to add buffer
else if (singleParam[0].equalsIgnoreCase(listBufferParameters[5])) {
if (singleParam[1].equalsIgnoreCase(sideOptions[0])) {
- // It defaults to square end cap style when side is specified
- bufferParameters.setEndCapStyle(BufferParameters.CAP_SQUARE);
+ // Default value is 'both'
continue;
} else if (singleParam[1].equalsIgnoreCase(sideOptions[1])
|| singleParam[1].equalsIgnoreCase(sideOptions[2])) {
bufferParameters.setSingleSided(true);
+
+ // Specifying 'left' or 'right' defaults to square end cap style
when side is specified
+ if (!endCapSpecified) {
+ bufferParameters.setEndCapStyle(BufferParameters.CAP_SQUARE);
+ }
Review Comment:
Good catch! Can you add Java tests for this change?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]