Skip to content

Commit

Permalink
Fix NPE in HyperlinkDetector
Browse files Browse the repository at this point in the history
  • Loading branch information
dmitrygusev committed Oct 4, 2013
1 parent 657a3da commit bde1221
Showing 1 changed file with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,11 @@ public IHyperlink[] detectHyperlinks(ITextViewer textViewer,

ITextFileBuffer fileBuffer = bufferManager.getTextFileBuffer(document);

if (fileBuffer == null)
{
return null;
}

IPath fileLocation = fileBuffer.getLocation();

if (fileLocation == null || !TapestryUtils.isTemplateFile(fileLocation))
Expand Down

0 comments on commit bde1221

Please sign in to comment.