diff --git a/platform/core-api/src/com/intellij/util/indexing/ID.java b/platform/core-api/src/com/intellij/util/indexing/ID.java index 2a8df58a4f73..8ae1a0ad6195 100644 --- a/platform/core-api/src/com/intellij/util/indexing/ID.java +++ b/platform/core-api/src/com/intellij/util/indexing/ID.java @@ -1,4 +1,4 @@ -// Copyright 2000-2021 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file. +// Copyright 2000-2022 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license. package com.intellij.util.indexing; import com.intellij.ide.plugins.PluginUtil; @@ -187,8 +187,9 @@ public class ID extends IndexId { @ApiStatus.Internal public synchronized static void unloadId(@NotNull ID id) { - ID oldID = ourIdObjects.remove(id.getName()); - LOG.assertTrue(id.equals(oldID)); + String name = id.getName(); + ID oldID = ourIdObjects.remove(name); + LOG.assertTrue(id.equals(oldID), "Failed to unload: " + name); ourIdToPluginId.remove(id); ourIdToRegistrationStackTrace.remove(id); }