fix duplicate plugin update notifications: don't queue the next plugin update while the network request from the previous update is still running
This commit is contained in:
@@ -71,8 +71,6 @@ class KotlinPluginUpdater(val propertiesComponent: PropertiesComponent) : Dispos
|
|||||||
|
|
||||||
private fun updateCheck() {
|
private fun updateCheck() {
|
||||||
try {
|
try {
|
||||||
checkQueued = false
|
|
||||||
|
|
||||||
var (mainRepoUpdateSuccess, latestVersionInRepository) = getPluginVersionFromMainRepository()
|
var (mainRepoUpdateSuccess, latestVersionInRepository) = getPluginVersionFromMainRepository()
|
||||||
var descriptorToInstall: IdeaPluginDescriptor? = null
|
var descriptorToInstall: IdeaPluginDescriptor? = null
|
||||||
var hostToInstallFrom: String? = null
|
var hostToInstallFrom: String? = null
|
||||||
@@ -94,6 +92,8 @@ class KotlinPluginUpdater(val propertiesComponent: PropertiesComponent) : Dispos
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
checkQueued = false
|
||||||
|
|
||||||
if (mainRepoUpdateSuccess || latestVersionInRepository != null) {
|
if (mainRepoUpdateSuccess || latestVersionInRepository != null) {
|
||||||
recordSuccessfulUpdateCheck()
|
recordSuccessfulUpdateCheck()
|
||||||
if (latestVersionInRepository != null && VersionComparatorUtil.compare(latestVersionInRepository, KotlinPluginUtil.getPluginVersion()) > 0) {
|
if (latestVersionInRepository != null && VersionComparatorUtil.compare(latestVersionInRepository, KotlinPluginUtil.getPluginVersion()) > 0) {
|
||||||
|
|||||||
Reference in New Issue
Block a user