mirror of
https://github.com/IntellectualSites/PlotSquared.git
synced 2024-11-23 05:36:45 +01:00
Deny negative ratings
This commit is contained in:
parent
1ee13ff96c
commit
c2b781da98
@ -187,7 +187,7 @@ public class Rate extends SubCommand {
|
|||||||
final int rating;
|
final int rating;
|
||||||
if (MathMan.isInteger(arg) && (arg.length() < 3) && (arg.length() > 0)) {
|
if (MathMan.isInteger(arg) && (arg.length() < 3) && (arg.length() > 0)) {
|
||||||
rating = Integer.parseInt(arg);
|
rating = Integer.parseInt(arg);
|
||||||
if (rating > 10) {
|
if (rating > 10 || rating < 1) {
|
||||||
sendMessage(player, C.RATING_NOT_VALID);
|
sendMessage(player, C.RATING_NOT_VALID);
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
Binary file not shown.
Loading…
Reference in New Issue
Block a user