mirror of https://github.com/apache/poi.git
remove unchecked cast from setHyperlink
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1891762 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
b08696f701
commit
50a4a3102f
|
@ -1064,7 +1064,12 @@ public final class XSSFCell extends CellBase {
|
|||
return;
|
||||
}
|
||||
|
||||
XSSFHyperlink link = (XSSFHyperlink)hyperlink;
|
||||
XSSFHyperlink link;
|
||||
if (hyperlink instanceof XSSFHyperlink) {
|
||||
link = (XSSFHyperlink)hyperlink;
|
||||
} else {
|
||||
link = new XSSFHyperlink(hyperlink);
|
||||
}
|
||||
|
||||
// Assign to us
|
||||
link.setCellReference( new CellReference(_row.getRowNum(), _cellNum).formatAsString() );
|
||||
|
|
Loading…
Reference in New Issue