diff options
author | PJ Fanning <fanningpj@apache.org> | 2022-02-22 08:49:15 +0000 |
---|---|---|
committer | PJ Fanning <fanningpj@apache.org> | 2022-02-22 08:49:15 +0000 |
commit | 32fa21596d881af9a0b6bd3a31f997659d6f5c2d (patch) | |
tree | 3b63e33dd352e230f5b5e406e249eb0cbd88b1a5 /poi | |
parent | 26978d373d62c2a6ae401583f3117979e7265b4b (diff) | |
download | poi-32fa21596d881af9a0b6bd3a31f997659d6f5c2d.tar.gz poi-32fa21596d881af9a0b6bd3a31f997659d6f5c2d.zip |
sonar issues
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1898311 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'poi')
-rw-r--r-- | poi/src/main/java/org/apache/poi/ss/formula/OperationEvaluationContext.java | 24 |
1 files changed, 6 insertions, 18 deletions
diff --git a/poi/src/main/java/org/apache/poi/ss/formula/OperationEvaluationContext.java b/poi/src/main/java/org/apache/poi/ss/formula/OperationEvaluationContext.java index 12e88abd51..29157de540 100644 --- a/poi/src/main/java/org/apache/poi/ss/formula/OperationEvaluationContext.java +++ b/poi/src/main/java/org/apache/poi/ss/formula/OperationEvaluationContext.java @@ -313,28 +313,16 @@ public final class OperationEvaluationContext { switch (part1refType) { case COLUMN: firstRow = 0; - if (part2refType.equals(NameType.COLUMN)) { - lastRow = ssVersion.getLastRowIndex(); - firstCol = parseRowRef(refStrPart1); - lastCol = parseRowRef(refStrPart2); - } else { - lastRow = ssVersion.getLastRowIndex(); - firstCol = parseColRef(refStrPart1); - lastCol = parseColRef(refStrPart2); - } + lastRow = ssVersion.getLastRowIndex(); + firstCol = parseColRef(refStrPart1); + lastCol = parseColRef(refStrPart2); break; case ROW: // support of cell range in the form of integer:integer firstCol = 0; - if (part2refType.equals(NameType.ROW)) { - firstRow = parseColRef(refStrPart1); - lastRow = parseColRef(refStrPart2); - lastCol = ssVersion.getLastColumnIndex(); - } else { - lastCol = ssVersion.getLastColumnIndex(); - firstRow = parseRowRef(refStrPart1); - lastRow = parseRowRef(refStrPart2); - } + lastCol = ssVersion.getLastColumnIndex(); + firstRow = parseRowRef(refStrPart1); + lastRow = parseRowRef(refStrPart2); break; case CELL: CellReference cr; |