Skip to content

Commit 7e5f1ad

Browse files
committed
fix RIDER-91651 Solution Explorer sometimes isn't properly loaded
1 parent 729ef97 commit 7e5f1ad

File tree

1 file changed

+7
-1
lines changed
  • rider/src/main/kotlin/com/jetbrains/rider/plugins/unity/explorer

1 file changed

+7
-1
lines changed

rider/src/main/kotlin/com/jetbrains/rider/plugins/unity/explorer/MetaTracker.kt

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,8 @@ import com.jetbrains.rd.util.addUnique
2323
import com.jetbrains.rider.plugins.unity.isUnityProjectFolder
2424
import com.jetbrains.rider.plugins.unity.workspace.getPackages
2525
import com.jetbrains.rider.projectDir
26+
import com.jetbrains.rider.projectView.solutionDirectory
27+
import com.jetbrains.rdclient.util.idea.toVirtualFile
2628
import com.jetbrains.rider.projectView.VfsBackendRequester
2729
import org.jetbrains.annotations.Nls
2830
import java.nio.file.Path
@@ -41,7 +43,11 @@ class MetaTracker : BulkFileListener, VfsBackendRequester, Disposable {
4143

4244
override fun after(events: MutableList<out VFileEvent>) {
4345
val projectManager = serviceIfCreated<ProjectManager>() ?: return
44-
val openedUnityProjects = projectManager.openProjects.filter { !it.isDisposed && it.isUnityProjectFolder() && !isUndoRedoInProgress(it)}.toList()
46+
val openedUnityProjects = projectManager.openProjects.filter {
47+
!it.isDisposed &&
48+
it.solutionDirectory.toVirtualFile(false) != null && // RIDER-91651 Solution Explorer sometimes isn't properly loaded
49+
it.isUnityProjectFolder() && !isUndoRedoInProgress(it)
50+
}.toList()
4551

4652
for (event in events) {
4753
if (!isValidEvent(event)) continue

0 commit comments

Comments
 (0)