What happens to ether sent along a function call of a contract.

ytriusytrius Member Posts: 26
If a function of a contract is called along with some ether (msg.value), is there needed some way to keep that ether in the contract or does it go to the contract by default ?

Comments

  • HippoClipHippoClip Member Posts: 16
    I think it goes to the contract by default ... unless the function "throw"s of course.
  • ytriusytrius Member Posts: 26
    HippoClip said:

    I think it goes to the contract by default ... unless the function "throw"s of course.

    Thanks! I think I figured that after more research. So I suppose you can direct funds immediately if you can verify msg.value >= threshold then you can do someAddress.send().

    This stuff is so cool
Sign In or Register to comment.