Skip to content
This repository has been archived by the owner on Jan 9, 2022. It is now read-only.

Commit

Permalink
Add withdraw restrictions to contract
Browse files Browse the repository at this point in the history
  • Loading branch information
Dhaiwat10 committed Apr 20, 2021
1 parent 51c79b8 commit 1b6b481
Show file tree
Hide file tree
Showing 5 changed files with 108,497 additions and 4 deletions.
2 changes: 1 addition & 1 deletion ADDRESS
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0xEccA7BF722455A94b9e759247aB86E2e1559c871
0x315cbA97683DA001462582979C14bd3552A7D244
2 changes: 2 additions & 0 deletions contracts/Faucet.sol
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,10 @@ import "hardhat/console.sol";

contract Faucet {
receive() external payable {}
address public creator = 0x0ED6Cec17F860fb54E21D154b49DAEFd9Ca04106;

function withdraw (address payable recepient) public {
require(msg.sender == creator);
recepient.transfer(100000000000000000);
}
}
108,478 changes: 108,478 additions & 0 deletions src/artifacts/build-info/a61cabd67266c9580c28c78524d0eedf.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion src/artifacts/contracts/Faucet.sol/Faucet.dbg.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{
"_format": "hh-sol-dbg-1",
"buildInfo": "..\\..\\build-info\\48ee6b6bf112ddd67318125b02dddd88.json"
"buildInfo": "..\\..\\build-info\\a61cabd67266c9580c28c78524d0eedf.json"
}
17 changes: 15 additions & 2 deletions src/artifacts/contracts/Faucet.sol/Faucet.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,19 @@
"contractName": "Faucet",
"sourceName": "contracts/Faucet.sol",
"abi": [
{
"inputs": [],
"name": "creator",
"outputs": [
{
"internalType": "address",
"name": "",
"type": "address"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
Expand All @@ -21,8 +34,8 @@
"type": "receive"
}
],
"bytecode": "0x608060405234801561001057600080fd5b5060fe8061001f6000396000f3fe608060405260043610601f5760003560e01c806351cff8d914602a576025565b36602557005b600080fd5b348015603557600080fd5b50607560048036036020811015604a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506077565b005b8073ffffffffffffffffffffffffffffffffffffffff166108fc67016345785d8a00009081150290604051600060405180830381858888f1935050505015801560c4573d6000803e3d6000fd5b505056fea2646970667358221220d13e149a03fc196c6871d0f03538a44db9e463071b6a9ca5535a4551274dd8ea64736f6c63430007060033",
"deployedBytecode": "0x608060405260043610601f5760003560e01c806351cff8d914602a576025565b36602557005b600080fd5b348015603557600080fd5b50607560048036036020811015604a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506077565b005b8073ffffffffffffffffffffffffffffffffffffffff166108fc67016345785d8a00009081150290604051600060405180830381858888f1935050505015801560c4573d6000803e3d6000fd5b505056fea2646970667358221220d13e149a03fc196c6871d0f03538a44db9e463071b6a9ca5535a4551274dd8ea64736f6c63430007060033",
"bytecode": "0x6080604052730ed6cec17f860fb54e21d154b49daefd9ca041066000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555034801561006457600080fd5b506101cf806100746000396000f3fe60806040526004361061002d5760003560e01c806302d05d3f1461003957806351cff8d91461007a57610034565b3661003457005b600080fd5b34801561004557600080fd5b5061004e6100cb565b604051808273ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b34801561008657600080fd5b506100c96004803603602081101561009d57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506100ef565b005b60008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b60008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161461014757600080fd5b8073ffffffffffffffffffffffffffffffffffffffff166108fc67016345785d8a00009081150290604051600060405180830381858888f19350505050158015610195573d6000803e3d6000fd5b505056fea2646970667358221220258c2cda539e1b8d188b847c810fcd71fffd510fbcefcd8ab01ae3538b22660664736f6c63430007060033",
"deployedBytecode": "0x60806040526004361061002d5760003560e01c806302d05d3f1461003957806351cff8d91461007a57610034565b3661003457005b600080fd5b34801561004557600080fd5b5061004e6100cb565b604051808273ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b34801561008657600080fd5b506100c96004803603602081101561009d57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506100ef565b005b60008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b60008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161461014757600080fd5b8073ffffffffffffffffffffffffffffffffffffffff166108fc67016345785d8a00009081150290604051600060405180830381858888f19350505050158015610195573d6000803e3d6000fd5b505056fea2646970667358221220258c2cda539e1b8d188b847c810fcd71fffd510fbcefcd8ab01ae3538b22660664736f6c63430007060033",
"linkReferences": {},
"deployedLinkReferences": {}
}

1 comment on commit 1b6b481

@vercel
Copy link

@vercel vercel bot commented on 1b6b481 Apr 20, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.