mirror of
https://github.com/AppleDash/SaneEconomy.git
synced 2025-02-18 12:41:19 +01:00
Fix paging weirdness.
This commit is contained in:
parent
9eaab03c50
commit
2442261496
@ -43,7 +43,11 @@ public class BalanceTopCommand extends SaneEconomyCommand {
|
|||||||
|
|
||||||
if (args.length == 1) {
|
if (args.length == 1) {
|
||||||
try {
|
try {
|
||||||
offset = 10 * Math.abs(Integer.parseInt(args[0]));
|
int page = Math.abs(Integer.parseInt(args[0]));
|
||||||
|
if (page > 1) {
|
||||||
|
page--;
|
||||||
|
}
|
||||||
|
offset = 10 * page;
|
||||||
} catch (NumberFormatException e) {
|
} catch (NumberFormatException e) {
|
||||||
MessageUtils.sendMessage(sender, "%s is not a valid number.");
|
MessageUtils.sendMessage(sender, "%s is not a valid number.");
|
||||||
return;
|
return;
|
||||||
|
@ -34,7 +34,7 @@ public class MapUtil {
|
|||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (newMap.size() > amount) {
|
if (newMap.size() >= amount) {
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user