mirror of
https://github.com/priyanshujain/sanderling.git
synced 2026-10-03 03:27:10 +00:00
fix(folio-spec): pick account card via seeded from(), not Math.random
Math.random() breaks --seed reproducibility. The verifier's seeded RNG flows through from(), so re-running a seed now produces the same card pick sequence.
This commit is contained in:
1 parent
0bce959d34
commit
25e6725f91
2 files changed
+44
-1
No files matched your search
@@ -162,7 +162,7 @@ const addTxn = actions(() => {
|
||||
if (route.current === "home") {
|
||||
const cards = accountCards.current;
|
||||
if (cards.length === 0) return [];
|
||||
return [Tap({ on: cards[Math.floor(Math.random() * cards.length)] })];
|
||||
return [Tap({ on: from(cards).generate() })];
|
||||
}
|
||||
if (route.current === "ledger") {
|
||||
const btn = addTxnButton.current;
|
||||
|
||||
Reference in new issue
Block a user