mirror of
https://github.com/plan-player-analytics/Plan.git
synced 2024-12-23 09:37:54 +01:00
Setting#toString now throws an exception
Setting#toString used to return the String value of the setting, and since that implementation is no longer present this method should not be called.
This commit is contained in:
parent
715111b433
commit
5dcdd0b9b1
@ -72,4 +72,13 @@ public abstract class Setting<T> {
|
||||
public boolean isValid(T value) {
|
||||
return validator.test(value);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
throw new UnsupportedOperationException(
|
||||
"Setting#toString should not be called, relies on old behavior. " +
|
||||
"Use getValueFrom(ConfigNode) instead. " +
|
||||
"(Called path: '" + path + "')"
|
||||
);
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user