@@ -16,23 +16,24 @@ import com.emberjs.navigation.EmberGotoRelatedProvider
1616import com.emberjs.psi.EmberNamedElement
1717import com.emberjs.resolver.EmberJSModuleReference
1818import com.intellij.injected.editor.VirtualFileWindow
19+ import com.intellij.javascript.JSModuleBaseReference
1920import com.intellij.lang.Language
2021import com.intellij.lang.ecmascript6.psi.ES6ImportExportDeclaration
2122import com.intellij.lang.ecmascript6.psi.ES6ImportedBinding
2223import com.intellij.lang.ecmascript6.resolve.ES6PsiUtil
2324import com.intellij.lang.injection.InjectedLanguageManager
24- import com.intellij.lang.javascript.frameworks.modules.JSModuleReferenceBase
25+ import com.intellij.lang.javascript.frameworks.amd.JSModuleReference
2526import com.intellij.lang.javascript.psi.*
2627import com.intellij.lang.javascript.psi.ecma6.*
2728import com.intellij.lang.javascript.psi.ecma6.impl.TypeScriptClassImpl
2829import com.intellij.lang.javascript.psi.ecma6.impl.TypeScriptTupleTypeImpl
2930import com.intellij.lang.javascript.psi.ecmal4.JSClass
3031import com.intellij.lang.javascript.psi.jsdoc.JSDocComment
3132import com.intellij.lang.javascript.psi.types.*
32- import com.intellij.lang.typescript.modules.TypeScriptFileModuleReference
3333import com.intellij.psi.*
3434import com.intellij.psi.impl.file.PsiDirectoryImpl
3535import com.intellij.psi.impl.source.resolve.reference.impl.providers.FileReference
36+ import com.intellij.psi.impl.source.resolve.reference.impl.providers.FileReferenceSet
3637import com.intellij.psi.impl.source.tree.LeafPsiElement
3738import com.intellij.psi.search.ProjectScope
3839import com.intellij.psi.util.PsiTreeUtil
@@ -259,9 +260,9 @@ class EmberUtils {
259260 fun followReferences (element : PsiElement ? , path : String? = null): PsiElement ? {
260261
261262 if (element is ES6ImportedBinding ) {
262- var ref: JSModuleReferenceBase ? = element.declaration?.fromClause?.references?.find { it is EmberJSModuleReference } as EmberJSModuleReference ?
263+ var ref: JSModuleReference ? = element.declaration?.fromClause?.references?.find { it is EmberJSModuleReference } as EmberJSModuleReference ?
263264 if (ref == null ) {
264- val tsFiles = element.declaration?.fromClause?.references?.mapNotNull { (it as ? TypeScriptFileModuleReference )?.resolve() }
265+ val tsFiles = element.declaration?.fromClause?.references?.mapNotNull { (it as ? FileReferenceSet )?.resolve() }
265266 return tsFiles?.maxByOrNull { it.virtualFile.path.length }
266267 }
267268
0 commit comments