Can't get file when event is invalid (EA-77748)
This commit is contained in:
+2
@@ -66,6 +66,7 @@ class LibraryModificationTracker(project: Project) : SimpleModificationTracker()
|
|||||||
|
|
||||||
private inline fun processBulk(events: List<VFileEvent>, check: (VirtualFile) -> Boolean) {
|
private inline fun processBulk(events: List<VFileEvent>, check: (VirtualFile) -> Boolean) {
|
||||||
events.forEach { event ->
|
events.forEach { event ->
|
||||||
|
if (event.isValid) {
|
||||||
val file = event.file
|
val file = event.file
|
||||||
if (file != null && check(file)) {
|
if (file != null && check(file)) {
|
||||||
incModificationCount()
|
incModificationCount()
|
||||||
@@ -73,6 +74,7 @@ class LibraryModificationTracker(project: Project) : SimpleModificationTracker()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// if library points to a jar, the jar does not pass isInLibraryClasses check, so we have to perform additional check for this case
|
// if library points to a jar, the jar does not pass isInLibraryClasses check, so we have to perform additional check for this case
|
||||||
private fun isLibraryArchiveRoot(virtualFile: VirtualFile): Boolean {
|
private fun isLibraryArchiveRoot(virtualFile: VirtualFile): Boolean {
|
||||||
|
|||||||
Reference in New Issue
Block a user