diff options
| author | Thunderblade73 <85900443+Thunderblade73@users.noreply.github.com> | 2024-05-26 12:23:02 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-05-26 12:23:02 +0200 |
| commit | ea1385c77ffa8b9a4f98811fbf3e767c30d9edf7 (patch) | |
| tree | 668444c961f0e8fc23cf5e52b38c11e33ad74b11 /src/main/java/at/hannibal2/skyhanni/utils | |
| parent | a214c141696f054b79c6ac13cb309992e3ac95d1 (diff) | |
| download | skyhanni-ea1385c77ffa8b9a4f98811fbf3e767c30d9edf7.tar.gz skyhanni-ea1385c77ffa8b9a4f98811fbf3e767c30d9edf7.tar.bz2 skyhanni-ea1385c77ffa8b9a4f98811fbf3e767c30d9edf7.zip | |
Fix Typos (#1897)
Diffstat (limited to 'src/main/java/at/hannibal2/skyhanni/utils')
6 files changed, 8 insertions, 8 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/utils/ChatUtils.kt b/src/main/java/at/hannibal2/skyhanni/utils/ChatUtils.kt index 1448cd250..94cdc4f0d 100644 --- a/src/main/java/at/hannibal2/skyhanni/utils/ChatUtils.kt +++ b/src/main/java/at/hannibal2/skyhanni/utils/ChatUtils.kt @@ -67,7 +67,7 @@ object ChatUtils { * Why deprecate this? Even if this message is descriptive for the user and the developer, * we don't want inconsistencies in errors, and we would need to search * for the code line where this error gets printed any way. - * so it's better to use the stack trace still. + * So it's better to use the stack trace still. * * @param message The message to be sent * diff --git a/src/main/java/at/hannibal2/skyhanni/utils/ColorUtils.kt b/src/main/java/at/hannibal2/skyhanni/utils/ColorUtils.kt index b7dbce754..52656f6ad 100644 --- a/src/main/java/at/hannibal2/skyhanni/utils/ColorUtils.kt +++ b/src/main/java/at/hannibal2/skyhanni/utils/ColorUtils.kt @@ -5,7 +5,7 @@ import kotlin.math.max object ColorUtils { - /** transfer string colors from the config to java.awt.Color */ + /** Transfer string colors from the config to java.awt.Color */ fun String.toChromaColor() = Color(toChromaColorInt(), true) fun String.toChromaColorInt() = SpecialColour.specialToChromaRGB(this) diff --git a/src/main/java/at/hannibal2/skyhanni/utils/ConditionalUtils.kt b/src/main/java/at/hannibal2/skyhanni/utils/ConditionalUtils.kt index 1ee91774b..00aec1dc5 100644 --- a/src/main/java/at/hannibal2/skyhanni/utils/ConditionalUtils.kt +++ b/src/main/java/at/hannibal2/skyhanni/utils/ConditionalUtils.kt @@ -5,8 +5,8 @@ import io.github.notenoughupdates.moulconfig.observer.Property object ConditionalUtils { - fun <T> T.transformIf(condition: T.() -> Boolean, transofmration: T.() -> T) = - if (condition()) transofmration(this) else this + fun <T> T.transformIf(condition: T.() -> Boolean, transformation: T.() -> T) = + if (condition()) transformation(this) else this fun <T> T.conditionalTransform(condition: Boolean, ifTrue: T.() -> Any, ifFalse: T.() -> Any) = if (condition) ifTrue(this) else ifFalse(this) diff --git a/src/main/java/at/hannibal2/skyhanni/utils/ItemUtils.kt b/src/main/java/at/hannibal2/skyhanni/utils/ItemUtils.kt index be314a030..90ef85025 100644 --- a/src/main/java/at/hannibal2/skyhanni/utils/ItemUtils.kt +++ b/src/main/java/at/hannibal2/skyhanni/utils/ItemUtils.kt @@ -344,13 +344,13 @@ object ItemUtils { fun NEUInternalName.isRune(): Boolean = contains("_RUNE;") - // use when showing the item name to the user (in guis, chat message, etc), not for comparing + // use when showing the item name to the user (in guis, chat message, etc.), not for comparing val ItemStack.itemName: String get() = getInternalName().itemName val ItemStack.itemNameWithoutColor: String get() = itemName.removeColor() - // use when showing the item name to the user (in guis, chat message, etc), not for comparing + // use when showing the item name to the user (in guis, chat message, etc.), not for comparing val NEUInternalName.itemName: String get() = itemNameCache.getOrPut(this) { grabItemName() } diff --git a/src/main/java/at/hannibal2/skyhanni/utils/NumberUtil.kt b/src/main/java/at/hannibal2/skyhanni/utils/NumberUtil.kt index 5df1915c0..d533dfc42 100644 --- a/src/main/java/at/hannibal2/skyhanni/utils/NumberUtil.kt +++ b/src/main/java/at/hannibal2/skyhanni/utils/NumberUtil.kt @@ -46,7 +46,7 @@ object NumberUtil { fun format(value: Number, preciseBillions: Boolean = false): String { @Suppress("NAME_SHADOWING") val value = value.toLong() - // Long.MIN_VALUE == -Long.MIN_VALUE so we need an adjustment here + // Long.MIN_VALUE == -Long.MIN_VALUE, so we need an adjustment here if (value == Long.MIN_VALUE) return format(Long.MIN_VALUE + 1, preciseBillions) if (value < 0) return "-" + format(-value, preciseBillions) diff --git a/src/main/java/at/hannibal2/skyhanni/utils/StringUtils.kt b/src/main/java/at/hannibal2/skyhanni/utils/StringUtils.kt index 4e5bce010..4e87646fe 100644 --- a/src/main/java/at/hannibal2/skyhanni/utils/StringUtils.kt +++ b/src/main/java/at/hannibal2/skyhanni/utils/StringUtils.kt @@ -464,7 +464,7 @@ object StringUtils { } /** - * Removes starting and ending reset formattings that dont sever a benefit at all. + * Removes starting and ending reset formattings that don't sever a benefit at all. */ fun String.stripHypixelMessage(): String { var message = this |
