Merge pull request #2 from SKBotNL/master

Change notes argument in certain API functions to be nullable
This commit was merged in pull request #2.
This commit is contained in:
NotAlexNoyle authored and GitHub committed 2025-06-11 12:50:09 -04:00
commit 827e47c6a9
1 file changed
+8 -8
@@ -57,7 +57,7 @@ class DiamondBankAPI(private var postgreSQL: PostgreSQL) {
uuid: UUID,
shards: Int,
transactionReason: String,
notes: String
notes: String?
): CompletableFuture<Unit> {
if (DiamondBankOG.economyDisabled) throw DiamondBankException.EconomyDisabledException
return DiamondBankOG.scope.future {
@@ -104,7 +104,7 @@ class DiamondBankAPI(private var postgreSQL: PostgreSQL) {
uuid: UUID,
shards: Int,
transactionReason: String,
notes: String
notes: String?
): CompletableFuture<Unit> {
if (DiamondBankOG.economyDisabled) throw DiamondBankException.EconomyDisabledException
@@ -156,7 +156,7 @@ class DiamondBankAPI(private var postgreSQL: PostgreSQL) {
uuid: UUID,
shards: Int,
transactionReason: String,
notes: String
notes: String?
): CompletableFuture<Unit> {
if (DiamondBankOG.economyDisabled) throw DiamondBankException.EconomyDisabledException
@@ -208,7 +208,7 @@ class DiamondBankAPI(private var postgreSQL: PostgreSQL) {
uuid: UUID,
shards: Int,
transactionReason: String,
notes: String
notes: String?
): CompletableFuture<Unit> {
if (DiamondBankOG.economyDisabled) throw DiamondBankException.EconomyDisabledException
@@ -341,7 +341,7 @@ class DiamondBankAPI(private var postgreSQL: PostgreSQL) {
uuid: UUID,
shards: Int,
transactionReason: String,
notes: String
notes: String?
): CompletableFuture<Unit> {
if (DiamondBankOG.economyDisabled) throw DiamondBankException.EconomyDisabledException
@@ -399,7 +399,7 @@ class DiamondBankAPI(private var postgreSQL: PostgreSQL) {
DiamondBankException.OtherException::class
)
@Suppress("unused")
fun withdrawFromPlayer(uuid: UUID, shards: Int, transactionReason: String, notes: String): CompletableFuture<Unit> {
fun withdrawFromPlayer(uuid: UUID, shards: Int, transactionReason: String, notes: String?): CompletableFuture<Unit> {
if (DiamondBankOG.economyDisabled) throw DiamondBankException.EconomyDisabledException
return DiamondBankOG.scope.future {
@@ -466,7 +466,7 @@ class DiamondBankAPI(private var postgreSQL: PostgreSQL) {
receiverUuid: UUID,
shards: Int,
transactionReason: String,
notes: String
notes: String?
): CompletableFuture<Unit> {
if (DiamondBankOG.economyDisabled) throw DiamondBankException.EconomyDisabledException
@@ -546,7 +546,7 @@ class DiamondBankAPI(private var postgreSQL: PostgreSQL) {
receiverUuid: UUID,
shards: Int,
transactionReason: String,
notes: String
notes: String?
): CompletableFuture<Unit> {
if (DiamondBankOG.economyDisabled) throw DiamondBankException.EconomyDisabledException