TootComposer: fix placeholder empty
This commit is contained in:
parent
63603e049d
commit
d90876a84e
1 changed files with 2 additions and 1 deletions
|
@ -183,7 +183,8 @@ function randomChoose<T extends any[]>(
|
|||
rn: number,
|
||||
K: T,
|
||||
): T extends Array<infer E> ? E : never {
|
||||
const idx = Math.round(rn * K.length) - 1;
|
||||
const idx = Math.floor(rn * K.length);
|
||||
console.log(idx, K.length);
|
||||
return K[idx];
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue