Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
2.13
-
None
Description
c1608113 introduced this:
- int line = event.getLine(); if ( getXrefLocation() != null ) { - sink - .link( - getXrefLocation() + "/" + filename.replaceAll( "\\.java$", ".html" ) + "#L" + line ); + sink.link( getXrefLocation() + "/" + filename.replaceAll( "\\.java$", ".html" ) + "#L" + + event.getLine() ); + sink.text( String.valueOf( event.getLine() ) ); + sink.link_(); } - if ( line != 0 ) + else { sink.text( String.valueOf( event.getLine() ) ); } - if ( getXrefLocation() != null ) - { - sink.link_(); - }
I have intentionally added if ( line != 0 ) to avoid useless Line 0 links. Moreover, int line avoids repetitive calls to event.getLine().
That improvement should remain.