diff --git a/docs/docs/basil.md b/docs/docs/basil.md index ce14f8a..873967f 100644 --- a/docs/docs/basil.md +++ b/docs/docs/basil.md @@ -37,7 +37,7 @@ npm init --yes Next, let's take a look at the `Basil` contract we will use to control the light bulb: ```sol -pragma solidity ^0.4.21; +pragma solidity ^0.4.24; import "openzeppelin-zos/contracts/ownership/Ownable.sol"; @@ -67,17 +67,17 @@ contract Basil is Ownable { g = _g; b = _b; highestDonation = msg.value; - NewDonation( + emit NewDonation( msg.sender, msg.value, r, g, b); } function withdraw(address wallet) public onlyOwner { - require(this.balance > 0); + require(address(this).balance > 0); require(wallet != address(0)); - uint256 value = this.balance; + uint256 value = address(this).balance; wallet.transfer(value); - Withdrawal(wallet, value); + emit Withdrawal(wallet, value); } } ``` @@ -117,7 +117,7 @@ By now, the json files looks like this: } ``` -OpenZeppelin will use this file to track your project's contracts on chain, making them upgradeable and dynamically linkable to pre-deployed libraries, as well see soon. +OpenZeppelin will use this file to track your project's contracts on chain, making them upgradeable and dynamically linkable to pre-deployed libraries, as we'll see soon. ## Deploying our first version of Basil, locally @@ -164,7 +164,7 @@ Another common thing that happens when developing smart contracts for Ethereum i We could modify `contracts/Basil.sol`. But now let's try something else. Let's make a new contract in `contracts/BasilERC721.sol`, that inherits from our initial version of Basil: ```sol -pragma solidity ^0.4.21; +pragma solidity ^0.4.24; import "./Basil.sol"; import "openzeppelin-zos/contracts/token/ERC721/MintableERC721Token.sol"; diff --git a/docs/docs/building.md b/docs/docs/building.md index 27aed49..5bf7653 100644 --- a/docs/docs/building.md +++ b/docs/docs/building.md @@ -15,7 +15,7 @@ npm install zos-lib Next, let's create a file named `MyContract.sol` in the `contracts/` folder with the following Solidity code: ```js -pragma solidity ^0.4.21; +pragma solidity ^0.4.24; import "zos-lib/contracts/migrations/Migratable.sol"; contract MyContract is Migratable { diff --git a/docs/docs/low_level_app.md b/docs/docs/low_level_app.md index ee7f44f..1de8c7a 100644 --- a/docs/docs/low_level_app.md +++ b/docs/docs/low_level_app.md @@ -34,7 +34,7 @@ await App.deploy(initialVersion) An initial version of the Solidity contract could look like: ```sol -pragma solidity ^0.4.21; +pragma solidity ^0.4.24; import "openzeppelin-zos/contracts/ownership/Ownable.sol"; import "openzeppelin-zos/contracts/math/SafeMath.sol"; @@ -87,7 +87,7 @@ npm install openzeppelin-zos Done! Now we can easily mint non-fungible tokens from our smart contract: ```sol -pragma solidity ^0.4.21; +pragma solidity ^0.4.24; import "./DonationsV0.sol"; import "openzeppelin-zos/contracts/token/ERC721/MintableERC721Token.sol";