From 853d9a74182d80c6c06c436f8e5f6d0a46152b11 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=A2=A6=E5=A2=83=E8=BF=B7=E7=A6=BB?= Date: Sun, 17 Dec 2023 12:43:08 +0800 Subject: [PATCH] Remove Navigatable cache --- .../analyzer/action/SbtDependencyAnalyzerGoToAction.scala | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/src/main/scala/bitlap/sbt/analyzer/action/SbtDependencyAnalyzerGoToAction.scala b/src/main/scala/bitlap/sbt/analyzer/action/SbtDependencyAnalyzerGoToAction.scala index e43e110..09c19c6 100644 --- a/src/main/scala/bitlap/sbt/analyzer/action/SbtDependencyAnalyzerGoToAction.scala +++ b/src/main/scala/bitlap/sbt/analyzer/action/SbtDependencyAnalyzerGoToAction.scala @@ -27,7 +27,6 @@ final class SbtDependencyAnalyzerGoToAction extends DependencyAnalyzerGoToAction ) private val LOG = Logger.getInstance(classOf[SbtDependencyAnalyzerGoToAction]) - private var declaredDependencies: List[DeclaredDependency] = _ override def getNavigatable(e: AnActionEvent): Navigatable = Option(getDeclaredDependency(e)).flatMap { dependency => @@ -55,12 +54,7 @@ final class SbtDependencyAnalyzerGoToAction extends DependencyAnalyzerGoToAction val module = getParentModule(project, dependency) if (coordinates == null || module == null) return null - val declared = - if (declaredDependencies == null) { - declaredDependencies = DependencyUtils.getDeclaredDependency(module) - declaredDependencies - } else declaredDependencies - + val declared = DependencyUtils.getDeclaredDependency(module) declared .find(dc => if (