Skip to content

0.4.21 event update #45

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions tutorial-25/contracts/MultiSigWallet.sol
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
pragma solidity ^0.4.0;
pragma solidity ^0.4.21;

contract MultiSigWallet {

Expand Down Expand Up @@ -54,7 +54,7 @@ contract MultiSigWallet {
function ()
public
payable {
DepositFunds(msg.sender, msg.value);
emit DepositFunds(msg.sender, msg.value);
}

function withdraw(uint amount)
Expand All @@ -77,7 +77,7 @@ contract MultiSigWallet {
_transactions[transactionId] = transaction;
_pendingTransactions.push(transactionId);

TransactionCreated(msg.sender, to, amount, transactionId);
emit TransactionCreated(msg.sender, to, amount, transactionId);
}

function getPendingTransactions()
Expand All @@ -104,12 +104,12 @@ contract MultiSigWallet {
transaction.signatures[msg.sender] = 1;
transaction.signatureCount++;

TransactionSigned(msg.sender, transactionId);
emit TransactionSigned(msg.sender, transactionId);

if (transaction.signatureCount >= MIN_SIGNATURES) {
require(address(this).balance >= transaction.amount);
transaction.to.transfer(transaction.amount);
TransactionCompleted(transaction.from, transaction.to, transaction.amount, transactionId);
emit TransactionCompleted(transaction.from, transaction.to, transaction.amount, transactionId);
deleteTransaction(transactionId);
}
}
Expand Down