Add Minimum Balance, to allow people to manage overdrafts.

This commit is contained in:
KHobbits 2012-02-26 04:15:14 +00:00
parent 13d3cc3306
commit 9f893e68e9
9 changed files with 57 additions and 7 deletions

View file

@ -539,6 +539,22 @@ public class Settings implements ISettings
}
return max;
}
private final static double MINMONEY = -10000000000000.0;
@Override
public double getMinMoney()
{
double min = config.getDouble("min-money", MINMONEY);
if (min > 0) {
min = -min;
}
if (min < MINMONEY)
{
min = MINMONEY;
}
return min;
}
@Override
public boolean isEcoLogEnabled()