mirror of
https://github.com/0xJacky/nginx-ui.git
synced 2025-05-11 10:25:52 +02:00
fix: build for 32-bit platform
This commit is contained in:
parent
9184711d43
commit
69a7f38ba7
2 changed files with 3 additions and 3 deletions
|
@ -19,8 +19,8 @@ type RecoveryCodesResponse struct {
|
|||
}
|
||||
|
||||
func generateRecoveryCode() string {
|
||||
// generate recovery code, 10 hex numbers
|
||||
return fmt.Sprintf("%010x", rand.Intn(0x10000000000))
|
||||
// generate recovery code, 10 hex numbers with a dash in the middle
|
||||
return fmt.Sprintf("%05x-%05x", rand.Intn(0x100000), rand.Intn(0x100000))
|
||||
}
|
||||
|
||||
func generateRecoveryCodes(count int) []model.RecoveryCode {
|
||||
|
|
|
@ -108,7 +108,7 @@ function handlePopOpenChange(visible: boolean) {
|
|||
<ul class="grid grid-cols-2 gap-2 text-lg">
|
||||
<li v-for="(code, index) in codes" :key="index">
|
||||
<span :class="{ 'line-through': code.used_time }">
|
||||
{{ `${code.code.slice(0, 5)}-${code.code.slice(5)}` }}
|
||||
{{ code.code }}
|
||||
</span>
|
||||
</li>
|
||||
</ul>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue