Skip to content

Commit 88f49e5

Browse files
fix:compiler version
1 parent b4ffd95 commit 88f49e5

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

contracts/Lottery.sol

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
// SPDX-License-Identifier: MIT
2-
pragma solidity ^0.8.12;
2+
pragma solidity ^0.8.20;
33

44
import "@openzeppelin/contracts/utils/Strings.sol";
55

@@ -63,7 +63,7 @@ contract Lottery {
6363
* @return index of the player within our list
6464
*/
6565
function random() private view returns (uint) {
66-
return uint(keccak256(abi.encodePacked(block.difficulty, block.timestamp, players)));
66+
return uint(keccak256(abi.encodePacked(block.prevrandao, block.timestamp, players)));
6767
}
6868

6969
/**

0 commit comments

Comments
 (0)