mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-01-08 15:09:39 +07:00
EA-36169 - NPE: JspTypedHandler.handleJspEqual
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2000-2009 JetBrains s.r.o.
|
||||
* Copyright 2000-2012 JetBrains s.r.o.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -27,6 +27,7 @@ public class JspPsiUtil {
|
||||
return getJspFile(element) != null;
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public static JspFile getJspFile(final PsiElement element) {
|
||||
final PsiFile psiFile = PsiUtilCore.getTemplateLanguageFile(element);
|
||||
return psiFile instanceof JspFile ? (JspFile)psiFile : null;
|
||||
|
||||
Reference in New Issue
Block a user