code: public void attachChangeListener(Setting setting) {
      ChangeListener changeEvent = (observable, oldValue, newValue) -> {
        if (isListenerActive() && oldValue != newValue) {
          LOGGER.trace("Change detected, old: " + oldValue + " new: " + newValue);
          addChange(new Change(setting, oldValue, newValue));
        }
      };
      ChangeListener listChangeEvent = (observable, oldValue, newValue) -> {
        if (isListenerActive()) {
          LOGGER.trace("List Change detected: " + oldValue);
          addChange(new Change(setting, (ObservableList) oldValue, (ObservableList) newValue));
        }
      };
  
      if (setting.valueProperty() instanceof SimpleListProperty) {
        setting.valueProperty().addListener(listChangeEvent);
      } else {
        setting.valueProperty().addListener(changeEvent);
      }
    }
docs: Adds a listener to the {@code setting}, so every time the value of the {@code setting} changes,
  a new {@link Change} will be created and added to the list of changes.
  
  @param setting the setting to observe for changes