Skip to content

Commit

Permalink
Merge pull request #14 from Hats-Protocol/hats-module-v0.5.0
Browse files Browse the repository at this point in the history
Upgrade to hats-module v0.5.0
  • Loading branch information
gershido authored Aug 28, 2023
2 parents 8ff1ef0 + ec2b103 commit 2cd7c9c
Show file tree
Hide file tree
Showing 7 changed files with 14 additions and 11 deletions.
6 changes: 3 additions & 3 deletions .gitmodules
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@
[submodule "lib/hats-protocol"]
path = lib/hats-protocol
url = https://github.com/Hats-Protocol/hats-protocol
[submodule "lib/hats-module"]
path = lib/hats-module
url = https://github.com/Hats-Protocol/hats-module
[submodule "lib/jokerace"]
path = lib/jokerace
url = https://github.com/jk-labs-inc/jokerace
[submodule "lib/hats-module"]
path = lib/hats-module
url = https://github.com/Hats-Protocol/hats-module
6 changes: 4 additions & 2 deletions foundry.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,15 @@ out = "out"
libs = ["lib"]
optimizer_runs = 1_000_000
auto_detect_solc = false
solc = "0.8.18"
solc = "0.8.19"
bytecode_hash = "none"
remappings = [
"ds-test/=lib/forge-std/lib/ds-test/src/",
"forge-std/=lib/forge-std/src/",
"hats-protocol/=lib/hats-protocol/src/",
"hats-module/=lib/hats-module/src/",
"jokerace/=lib/jokerace/packages/forge/src/"
"jokerace/=lib/jokerace/packages/forge/src/",
"solady/=lib/hats-module/lib/solady/src/"
]
gas_reports = ["JokeraceEligibility"]

Expand Down
1 change: 1 addition & 0 deletions remappings.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,4 @@ hats-protocol/=lib/hats-protocol/src/
hats-module/=lib/hats-module/src/
jokerace/=lib/jokerace/packages/forge/src/
@openzeppelin/=lib/jokerace/packages/forge/lib/openzeppelin-contracts/contracts/
solady/=lib/hats-module/lib/solady/src/
4 changes: 2 additions & 2 deletions script/JokeraceEligibility.s.sol
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// SPDX-License-Identifier: UNLICENSED
pragma solidity ^0.8.18;
pragma solidity ^0.8.19;

import { Script, console2 } from "forge-std/Script.sol";
import { JokeraceEligibility } from "../src/JokeraceEligibility.sol";
Expand All @@ -12,7 +12,7 @@ contract DeployImplementation is Script {
bytes32 public SALT = keccak256("lets add some salt to this meal");

// default values
string public version = "0.2.0"; // increment with each deploy
string public version = "0.3.0"; // increment with each deploy
bool private verbose = true;

/// @notice Override default values, if desired
Expand Down
4 changes: 2 additions & 2 deletions src/JokeraceEligibility.sol
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.18;
pragma solidity ^0.8.19;

// import { console2 } from "forge-std/Test.sol"; // remove before deploy
import { IHatsEligibility } from "hats-protocol/Interfaces/IHatsEligibility.sol";
Expand Down Expand Up @@ -89,7 +89,7 @@ contract JokeraceEligibility is HatsEligibilityModule {
* _termEnd - Final second of the current term (a unix timestamp), i.e. the point at which hats become inactive
* _topK - First K winners of the contest will be eligible
*/
function setUp(bytes calldata _initData) public override initializer {
function _setUp(bytes calldata _initData) internal override {
(address payable _underlyingContest, uint256 _termEnd, uint256 _topK) =
abi.decode(_initData, (address, uint256, uint256));
// initialize the mutable state vars
Expand Down
2 changes: 1 addition & 1 deletion test/JokeraceEligibility.t.sol
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// SPDX-License-Identifier: UNLICENSED
pragma solidity ^0.8.18;
pragma solidity ^0.8.19;

import { Test, console2 } from "forge-std/Test.sol";
import { JokeraceEligibility } from "../src/JokeraceEligibility.sol";
Expand Down

0 comments on commit 2cd7c9c

Please sign in to comment.