Created
December 29, 2021 11:54
-
-
Save zoernert/2566bbde081eb910d49b7ebc931ff6f3 to your computer and use it in GitHub Desktop.
Created using remix-ide: Realtime Ethereum Contract Compiler and Runtime. Load this file by pasting this gists URL or ID at https://remix.ethereum.org/#version=soljson-v0.8.11+commit.d7f03943.js&optimize=true&runs=200&gist=
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
pragma solidity ^0.8.0; | |
import "./espledger.sol"; | |
contract espaccounting { | |
mapping (address => espledger) public ledgers; | |
function transfer(address from,address to, uint256 value) public returns (bool success) { | |
espledger ledger = ledgers[msg.sender]; | |
if(address(ledger) == address(0)) { | |
ledger = new espledger(msg.sender); | |
ledgers[msg.sender] =ledger; | |
} | |
return ledger.transfer(from,to,value); | |
//return true; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment