mirror of
https://github.com/louislam/uptime-kuma.git
synced 2025-08-12 03:02:23 +08:00
fix for max-inclusive
This commit is contained in:
@@ -116,7 +116,7 @@ function genSecret(length = 64) {
|
|||||||
const chars = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";
|
const chars = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";
|
||||||
const charsLength = chars.length;
|
const charsLength = chars.length;
|
||||||
for ( let i = 0; i < length; i++ ) {
|
for ( let i = 0; i < length; i++ ) {
|
||||||
secret += chars.charAt(getCryptoRandomInt(0, charsLength));
|
secret += chars.charAt(getCryptoRandomInt(0, charsLength - 1));
|
||||||
}
|
}
|
||||||
return secret;
|
return secret;
|
||||||
}
|
}
|
||||||
|
@@ -128,7 +128,7 @@ export function genSecret(length = 64) {
|
|||||||
const chars = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";
|
const chars = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";
|
||||||
const charsLength = chars.length;
|
const charsLength = chars.length;
|
||||||
for ( let i = 0; i < length; i++ ) {
|
for ( let i = 0; i < length; i++ ) {
|
||||||
secret += chars.charAt(getCryptoRandomInt(0, charsLength));
|
secret += chars.charAt(getCryptoRandomInt(0, charsLength - 1));
|
||||||
}
|
}
|
||||||
return secret;
|
return secret;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user