Add item to config, while keeping notes?

Discussion in 'Plugin Development' started by Superior_Slime, Jan 10, 2015.

Thread Status:
Not open for further replies.
  1. Offline

    Superior_Slime

    My plugin auto-updates using Gravity's updater when a new version is released. If I add new features, how could I add new items to the config if they don't already exist while keeping notes? The methods I have attempted do not retain notes.

    Thanks in advance :)
     
  2. Offline

    Ganga

    You could save your old ones by adding this to you onDisable:
    getConfig.addDefaults(...);
    saveConfig;

    I guess then they stay every update.
     
Thread Status:
Not open for further replies.

Share This Page