Skip to content
This repository has been archived by the owner on Jan 1, 2024. It is now read-only.

Move all functions to the top-level #35

Merged
merged 8 commits into from
Aug 25, 2023
Merged

Move all functions to the top-level #35

merged 8 commits into from
Aug 25, 2023

Conversation

drakon64
Copy link
Owner

@drakon64 drakon64 commented Aug 20, 2023

  • Move all functions to the top-level
  • getCurrentMarketBoardData and getMarketBoardSaleHistory now accept itemId: Int or itemIds: Set<Int>
  • UniversalisException now provides more information about the server-side exception
  • Add overloads and checked exceptions for JVM Async functions

@drakon64 drakon64 self-assigned this Aug 20, 2023
@drakon64 drakon64 force-pushed the remove-object branch 2 times, most recently from 7d1f435 to 80262a8 Compare August 20, 2023 23:24
src/commonMain/kotlin/KtUniversalis.kt Outdated Show resolved Hide resolved
Comment on lines 130 to 155
if (listings != null) {
parameters.append("listings", listings.toString())
}
if (entries != null) {
parameters.append("entries", entries.toString())
}
if (noGst != null) {
parameters.append("noGst", noGst.toString())
}
if (hq != null) {
parameters.append("hq", hq.toString())
}
if (statsWithin != null) {
parameters.append("statsWithin", statsWithin.toString())
}
if (entriesWithin != null) {
parameters.append("entriesWithin", entriesWithin.toString())
}
if (fields != null) {
parameters.append("fields", fields.joinToString(","))
}

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would inline those ifs to have a more condensed view.
Also doesnt parameter cast to string internally anyway?

src/commonMain/kotlin/KtUniversalis.kt Outdated Show resolved Hide resolved
src/commonMain/kotlin/KtUniversalis.kt Outdated Show resolved Hide resolved
src/commonMain/kotlin/KtUniversalis.kt Outdated Show resolved Hide resolved
src/commonMain/kotlin/KtUniversalis.kt Outdated Show resolved Hide resolved
src/commonMain/kotlin/KtUniversalis.kt Outdated Show resolved Hide resolved
src/commonMain/kotlin/KtUniversalis.kt Outdated Show resolved Hide resolved
if (statsWithin != null) parameters.append(
"statsWithin", statsWithin.toString()
)

if (entriesWithin != null) parameters.append(
"entriesWithin", entriesWithin.toString()
)

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

weird line breaks

@drakon64 drakon64 force-pushed the remove-object branch 4 times, most recently from 6f56c0f to 4c953a1 Compare August 24, 2023 22:12
This should maintain backwards-compatability with existing Java code
@drakon64 drakon64 marked this pull request as ready for review August 25, 2023 19:57
@sonarcloud
Copy link

sonarcloud bot commented Aug 25, 2023

SonarCloud Quality Gate failed.    Quality Gate failed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 8 Code Smells

44.3% 44.3% Coverage
0.0% 0.0% Duplication

idea Catch issues before they fail your Quality Gate with our IDE extension sonarlint SonarLint

@drakon64 drakon64 merged commit 23a5c0f into main Aug 25, 2023
1 check failed
@drakon64 drakon64 deleted the remove-object branch August 25, 2023 20:04
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants