mirror of https://github.com/hykilpikonna/AquaDX
[F] Fix #68
parent
be7b0945e9
commit
4713a44573
|
@ -17,9 +17,9 @@ import org.springframework.scheduling.annotation.Scheduled
|
|||
import org.springframework.stereotype.Service
|
||||
import org.springframework.web.bind.annotation.RestController
|
||||
import java.time.LocalDateTime
|
||||
import java.time.ZoneOffset
|
||||
import kotlin.jvm.optionals.getOrNull
|
||||
import kotlin.random.Random
|
||||
import kotlin.random.nextULong
|
||||
|
||||
@RestController
|
||||
@API("/api/v2/card")
|
||||
|
@ -141,7 +141,7 @@ suspend fun <T : IUserData> migrateCard(repo: GenericUserDataRepo<T>, cardRepo:
|
|||
async { repo.findByCard(ghost) }?.let {
|
||||
// Create a new dummy card for deleted data
|
||||
it.card = async { cardRepo.save(Card().apply {
|
||||
luid = "Migrated data of ghost card ${ghost.id} for user ${card.aquaUser!!.auId}"
|
||||
luid = "Migrated data of ghost card ${ghost.id} for user ${card.aquaUser!!.auId} on ${LocalDateTime.now(ZoneOffset.UTC).isoDateTime()}"
|
||||
// Randomize an extId outside the normal range
|
||||
extId = Random.nextLong(0x7FFFFFF7L shl 32, 0x7FFFFFFFL shl 32)
|
||||
registerTime = LocalDateTime.now()
|
||||
|
|
Loading…
Reference in New Issue