From c2cbd377bc172a2fae07cbd162bff312d4598009 Mon Sep 17 00:00:00 2001 From: hannibal2 <24389977+hannibal00212@users.noreply.github.com> Date: Fri, 5 Apr 2024 18:42:41 +0200 Subject: code cleanup --- .../hannibal2/skyhanni/features/garden/pests/PestAPI.kt | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) (limited to 'src/main/java/at/hannibal2/skyhanni/features/garden') diff --git a/src/main/java/at/hannibal2/skyhanni/features/garden/pests/PestAPI.kt b/src/main/java/at/hannibal2/skyhanni/features/garden/pests/PestAPI.kt index 1af4e43b8..9c595de1e 100644 --- a/src/main/java/at/hannibal2/skyhanni/features/garden/pests/PestAPI.kt +++ b/src/main/java/at/hannibal2/skyhanni/features/garden/pests/PestAPI.kt @@ -319,9 +319,10 @@ object PestAPI { event.addIrrelevant("not in garden") return } - if (!config.pestFinder.showDisplay && !config.pestFinder.showPlotInWorld && - config.pestFinder.teleportHotkey == Keyboard.KEY_NONE - ) { + val disabled = with(config.pestFinder) { + !showDisplay && !showPlotInWorld && teleportHotkey == Keyboard.KEY_NONE + } + if (disabled) { event.addIrrelevant("disabled in config") return } @@ -331,10 +332,10 @@ object PestAPI { add("") getInfestedPlots().forEach { add("id: ${it.id}") - add("name: ${it.name}") - add("isPestCountInaccurate: ${it.isPestCountInaccurate}") - add("pests: ${it.pests}") - add("") + add(" name: ${it.name}") + add(" isPestCountInaccurate: ${it.isPestCountInaccurate}") + add(" pests: ${it.pests}") + add(" ") } } } -- cgit