From 0e1499cf9864ac141962cbe41c83dbd743707fcb Mon Sep 17 00:00:00 2001 From: Eugene Zhuravlev Date: Wed, 13 Jan 2016 12:17:14 +0100 Subject: [PATCH] ignore outdated properties when restoring registry defaults (IDEA-121047) --- .../src/com/intellij/openapi/util/registry/Registry.java | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/platform/util/src/com/intellij/openapi/util/registry/Registry.java b/platform/util/src/com/intellij/openapi/util/registry/Registry.java index 32e2e4fe7f13..89c60b09f70c 100644 --- a/platform/util/src/com/intellij/openapi/util/registry/Registry.java +++ b/platform/util/src/com/intellij/openapi/util/registry/Registry.java @@ -157,7 +157,13 @@ public class Registry { Map old = new HashMap(); old.putAll(myUserProperties); for (String each : old.keySet()) { - get(each).resetToDefault(); + try { + get(each).resetToDefault(); + } + catch (MissingResourceException e) { + // outdated property that is not declared in registry.properties anymore + myValues.remove(each); + } } }