private void setFileSizeThresholdMb()

in server/src/main/java/jetbrains/buildServer/torrent/TorrentConfigurator.java [124:134]


  private void setFileSizeThresholdMb(long threshold) {
    String oldValueStr = myConfiguration.getProperty(FILE_SIZE_THRESHOLD, DEFAULT_FILE_SIZE_THRESHOLD);
    long oldValue = 0;
    try {
      oldValue = StringUtil.parseFileSize(oldValueStr);
    } catch (NumberFormatException ignored) {}
    if (oldValue != threshold) {
      myConfiguration.setProperty(FILE_SIZE_THRESHOLD, String.valueOf(threshold));
      propertyChanged(FILE_SIZE_THRESHOLD, oldValue, threshold);
    }
  }