Skip to content

Commit

Permalink
change participants generation to not include 0
Browse files Browse the repository at this point in the history
  • Loading branch information
Ninjatosba committed Apr 12, 2024
1 parent 4ed59cb commit 7cb63da
Show file tree
Hide file tree
Showing 4 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion artifacts/checksums.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
de162873586b6f439f16b376b350950cfc12655b4e2aab41586583704906181a raffle_drop.wasm
12bf66626d6c7972664a19b0c6394cf65de38a831d84c2340a096656316a5859 raffle_drop.wasm
2 changes: 1 addition & 1 deletion artifacts/checksums_intermediate.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0e649e82934b9282d0c9f93d18918c69d92deaa9d45f68b71f41454a64418fb0 /target/wasm32-unknown-unknown/release/raffle_drop.wasm
45da052c35dc16f3d2080236dbf00daac2d7c2e8850c897871c3b7d614b52152 /target/wasm32-unknown-unknown/release/raffle_drop.wasm
Binary file modified artifacts/raffle_drop.wasm
Binary file not shown.
2 changes: 1 addition & 1 deletion src/contract.rs
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ pub fn execute_pick_winners(
.map_err(|_| ContractError::InvalidRandomness {})?;

let participant_count = PARTICIPANT_COUNT.load(deps.storage)?;
let participant_arr = (0..participant_count).collect::<Vec<u32>>();
let participant_arr = (1..=participant_count).collect::<Vec<u32>>();

let winners = pick(randomness, 100, participant_arr);
let winners_string = winners
Expand Down

0 comments on commit 7cb63da

Please sign in to comment.