mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
IDEA-90141 ClassCastException when using an xml based template (in a template dir) in a Django project.
This commit is contained in:
@@ -160,7 +160,9 @@ public class XmlNamespaceIndex extends XmlIndex<XsdNamespaceBuilder> {
|
||||
|
||||
IndexedRelevantResource<String,XsdNamespaceBuilder> resource =
|
||||
guessSchema(namespace, tagName, version, ModuleUtilCore.findModuleForPsiElement(file));
|
||||
return resource == null ? null : (XmlFile)file.getManager().findFile(resource.getFile());
|
||||
if (resource == null) return null;
|
||||
PsiFile psiFile = file.getManager().findFile(resource.getFile());
|
||||
return psiFile instanceof XmlFile ? (XmlFile)psiFile : null;
|
||||
}
|
||||
|
||||
@Nullable
|
||||
|
||||
Reference in New Issue
Block a user