refactor: use the new latest getFirst() instead of get(0)

This commit is contained in:
ChomeNS
2025-01-06 19:46:03 +07:00
parent ebc7560d2e
commit 7c861e1869
14 changed files with 18 additions and 18 deletions

View File

@@ -46,9 +46,9 @@ public class QueryPlugin extends Bot.Listener {
if (children.size() > 2) return false;
if (!(children.get(0) instanceof TextComponent)) return true;
if (!(children.getFirst() instanceof TextComponent)) return true;
final long transactionId = Integer.parseInt(((TextComponent) children.get(0)).content());
final long transactionId = Integer.parseInt(((TextComponent) children.getFirst()).content());
if (!transactions.containsKey(transactionId)) return true;