Fix Kits and Maybe? Locale
All checks were successful
SteamWarCI Build successful

Signed-off-by: Chaoscaot <max@maxsp.de>
This commit is contained in:
2025-12-20 21:35:34 +01:00
parent 9efe625603
commit 975b2bb8e6
3 changed files with 5 additions and 4 deletions

3
.gitignore vendored
View File

@@ -20,4 +20,5 @@ lib
/WebsiteBackend/data
/WebsiteBackend/logs
/WebsiteBackend/skins
/WebsiteBackend/config.json
/WebsiteBackend/config.json
/WebsiteBackend/sessions

View File

@@ -54,7 +54,7 @@ class InternalKit(id: EntityID<CompositeID>): CompositeEntity(id) {
@JvmStatic
fun get(userId: Int, gamemode: String, kitName: String) = useDb {
get(CompositeID {
findById(CompositeID {
it[PersonalKitTable.userId] = EntityID(userId, SteamwarUserTable)
it[PersonalKitTable.gamemode] = gamemode
it[PersonalKitTable.kitName] = kitName

View File

@@ -169,8 +169,8 @@ class SteamwarUser(id: EntityID<Int>): IntEntity(id) {
}
fun isLeader() = leader
var locale: Locale by SteamwarUserTable.locale
.transform({ it.toLanguageTag() }, { it?.let { Locale.forLanguageTag(it) } ?: Locale.getDefault()})
var locale: Locale? by SteamwarUserTable.locale
.transform({ it?.toLanguageTag() }, { it?.let { Locale.forLanguageTag(it) } })
var manualLocale by SteamwarUserTable.manualLocale
var bedrock by SteamwarUserTable.bedrock
private var passwordInternal by SteamwarUserTable.password