Skip to content

Commit

Permalink
compiles with new web3 (#58)
Browse files Browse the repository at this point in the history
  • Loading branch information
martyall authored Apr 22, 2018
1 parent 97c573c commit 71b4c0c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions bower.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@
],
"dependencies": {
"purescript-prelude": "^3.1.1",
"purescript-web3": "^0.21.0",
"purescript-web3-generator": "^0.21.0",
"purescript-web3": "^0.22.0",
"purescript-web3-generator": "^0.21.1",
"purescript-js-date": "^5.1.0",
"purescript-console": "^3.0.0",
"purescript-errors": "^3.0.0",
Expand Down
4 changes: 2 additions & 2 deletions src/Chanterelle/Internal/Deploy.purs
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ import Data.Lens.Index (ix)
import Data.Maybe (isNothing, fromJust)
import Data.StrMap as M
import Network.Ethereum.Web3 (runWeb3)
import Network.Ethereum.Web3.Types (NoPay, ETH, Web3, Address, BigNumber, HexString, TransactionOptions, TransactionReceipt(..), mkHexString, mkAddress)
import Network.Ethereum.Web3.Types (NoPay, ETH, Web3, Address, BigNumber, HexString, TransactionOptions, TransactionReceipt(..), TransactionStatus(..), mkHexString, mkAddress)
import Node.Encoding (Encoding(UTF8))
import Node.FS.Aff (FS, readTextFile, writeTextFile)
import Node.Path (FilePath)
Expand Down Expand Up @@ -89,7 +89,7 @@ getPublishedContractAddress txHash name = do
let message = "No Transaction Receipt found for deployment " <> show txHash
in throwError $ OnDeploymentError {name, message}
Right (TransactionReceipt txReceipt) ->
if txReceipt.status == "0x0" || isNothing (unNullOrUndefined txReceipt.contractAddress)
if txReceipt.status == Failed || isNothing (unNullOrUndefined txReceipt.contractAddress)
then
let message = "Deployment failed to create contract, no address found or status 0x0 in receipt: " <> name
in throwError $ OnDeploymentError {name, message}
Expand Down

0 comments on commit 71b4c0c

Please sign in to comment.