diff --git a/runelite-client/src/main/java/net/runelite/client/config/ConfigManager.java b/runelite-client/src/main/java/net/runelite/client/config/ConfigManager.java index b737f7a367..ac644c29d1 100644 --- a/runelite-client/src/main/java/net/runelite/client/config/ConfigManager.java +++ b/runelite-client/src/main/java/net/runelite/client/config/ConfigManager.java @@ -164,9 +164,6 @@ public class ConfigManager public final void switchSession(AccountSession session) { - // Ensure existing config is saved - sendConfig(); - if (session == null) { this.session = null; @@ -175,7 +172,6 @@ public class ConfigManager else { this.session = session; - this.configClient = new ConfigClient(okHttpClient, session.getUuid()); } this.propertiesFile = getPropertiesFile(); @@ -204,51 +200,7 @@ public class ConfigManager public void load() { - if (configClient == null) - { - loadFromFile(); - return; - } - - Configuration configuration; - - try - { - configuration = configClient.get(); - } - catch (IOException ex) - { - log.debug("Unable to load configuration from client, using saved configuration from disk", ex); - loadFromFile(); - return; - } - - if (configuration.getConfig() == null || configuration.getConfig().isEmpty()) - { - log.debug("No configuration from client, using saved configuration on disk"); - loadFromFile(); - return; - } - - Properties newProperties = new Properties(); - for (ConfigEntry entry : configuration.getConfig()) - { - newProperties.setProperty(entry.getKey(), entry.getValue()); - } - - log.debug("Loading in config from server"); - swapProperties(newProperties, false); - - try - { - saveToFile(propertiesFile); - - log.debug("Updated configuration on disk with the latest version"); - } - catch (IOException ex) - { - log.warn("Unable to update configuration on disk", ex); - } + loadFromFile(); } private void swapProperties(Properties newProperties, boolean saveToServer)