Minor: remove warnings in KotlinStructureViewFactory
This commit is contained in:
+5
-6
@@ -28,10 +28,12 @@ import org.jetbrains.kotlin.psi.KtFile;
|
|||||||
|
|
||||||
public class KotlinStructureViewFactory implements PsiStructureViewFactory {
|
public class KotlinStructureViewFactory implements PsiStructureViewFactory {
|
||||||
@Override
|
@Override
|
||||||
public StructureViewBuilder getStructureViewBuilder(PsiFile psiFile) {
|
public StructureViewBuilder getStructureViewBuilder(@NotNull PsiFile psiFile) {
|
||||||
if (psiFile instanceof KtFile) {
|
if (!(psiFile instanceof KtFile)) {
|
||||||
final KtFile file = (KtFile) psiFile;
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
KtFile file = (KtFile) psiFile;
|
||||||
return new TreeBasedStructureViewBuilder() {
|
return new TreeBasedStructureViewBuilder() {
|
||||||
@NotNull
|
@NotNull
|
||||||
@Override
|
@Override
|
||||||
@@ -40,7 +42,4 @@ public class KotlinStructureViewFactory implements PsiStructureViewFactory {
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
return null;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user