diff --git a/src/main/java/com/threerings/admin/server/ConfigRegistry.java b/src/main/java/com/threerings/admin/server/ConfigRegistry.java index e117c985c..723e20373 100644 --- a/src/main/java/com/threerings/admin/server/ConfigRegistry.java +++ b/src/main/java/com/threerings/admin/server/ConfigRegistry.java @@ -319,10 +319,7 @@ public abstract class ConfigRegistry } try { - ByteArrayInputStream bin = - new ByteArrayInputStream(StringUtil.unhexlate(value)); - ObjectInputStream oin = createObjectInputStream(bin); - Object deserializedValue = oin.readObject(); + Object deserializedValue = deserialize(value); field.set(object, deserializedValue); if (_transitioning) { // Use serialize rather than serializeAttribute so we don't get @@ -384,6 +381,17 @@ public abstract class ConfigRegistry } } + /** + * Deserializes the object contained in the specified string. + */ + protected Object deserialize (String value) + throws Exception + { + ByteArrayInputStream bin = new ByteArrayInputStream(StringUtil.unhexlate(value)); + ObjectInputStream oin = createObjectInputStream(bin); + return oin.readObject(); + } + /** * Converts a config object field name (someConfigMember) to a configuration key * (some_config_member).