Skip to content

Commit

Permalink
There might be cases that this action is not run within EDT, must be …
Browse files Browse the repository at this point in the history
…wrapped explicitly
  • Loading branch information
MarcinVaadin committed Oct 30, 2024
1 parent a3eb4be commit 9690c2d
Showing 1 changed file with 6 additions and 3 deletions.
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
package com.vaadin.plugin.copilot.listeners

import com.intellij.openapi.application.runInEdt
import com.intellij.openapi.application.runWriteAction
import com.intellij.openapi.project.Project
import com.intellij.openapi.project.ProjectManager
Expand All @@ -15,9 +16,11 @@ class CopilotVaadinProjectListener : VaadinProjectListener {
override fun vaadinProjectDetected(project: Project) {
if (!triggered) {
triggered = true
runWriteAction {
saveDotFile(project)
removeDotFileOnExit(project)
runInEdt {
runWriteAction {
saveDotFile(project)
removeDotFileOnExit(project)
}
}
}
}
Expand Down

0 comments on commit 9690c2d

Please sign in to comment.