Commit graph

8 commits

Author SHA1 Message Date
XZSt4nce
6498680b1f JSDoc returns Promises in async functions; Using DRY for ClientAccountID, BalanceOf etc; Added function ClientAccountMSPID; Added function CheckAuthorization; Using new function _update for minting, burning and transfering tokens; Additional functions for approving, spending allowance and checking empty values; Updated and repaired tests
Signed-off-by: XZSt4nce <xzstnc@mail.ru>
2025-03-08 02:44:44 +03:00
ali
05c06f4931
Fixed comment consistency problem (#844)
* fixed comment consistency problem with erc20 chaincode

Signed-off-by: Ali Shahverdi <ali@Alis-MacBook-Pro.local>

* added more comment consistancy fix

Signed-off-by: Ali Shahverdi <ali@Alis-MacBook-Pro.local>

* added more comment consistancy fix

Signed-off-by: Ali Shahverdi <ali@Alis-MacBook-Pro.local>

* added more comment consistancy fix

Signed-off-by: Ali Shahverdi <ali@Alis-MacBook-Pro.local>

* added more comment consistancy fix

Signed-off-by: Ali Shahverdi <ali@Alis-MacBook-Pro.local>

Signed-off-by: Ali Shahverdi <ali@Alis-MacBook-Pro.local>
Co-authored-by: Ali Shahverdi <ali@Alis-MacBook-Pro.local>
2022-12-14 09:18:21 +01:00
fraVlaca
67a1166396 added fixes to erc token samples and documentation
Signed-off-by: fraVlaca <ocsenarf@outlook.com>
2022-05-18 07:54:36 -04:00
fraVlaca
5f71466295
updated erc tokens samples (#731)
Signed-off-by: fraVlaca <ocsenarf@outlook.com>
2022-05-11 10:35:10 -04:00
Arnaud J Le Hors
6d043af487 Add repolinter support
Fix link in SECURITY file, and add missing copyright and license
notices.

To check, run: repolinter --rulesetUrl https://github.com/hyperledger-labs/hyperledger-community-management-tools/raw/main/repo_structure/repolint.json

Signed-off-by: Arnaud J Le Hors <lehors@us.ibm.com>
2021-04-23 15:35:20 -04:00
Simon Stone
365172ddb3
Stop ERC-20 transfer bug when to/from accounts are the same (#425)
Using the ERC-20 sample, you can submit a transfer to and from
the same account. Because the code doesn't handle this, it ends
up minting new tokens into that account.

The correct behaviour is not specified by the ERC-20 specification,
although the OpenZeppelin implementation seems to permit it.

IMO we should just block it with an error because I can't see a use
case for allowing it and it is most likely a user error.

Signed-off-by: Simon Stone <sstone1@uk.ibm.com>
2021-02-24 15:07:06 -05:00
5pecia1
ca5c16dbae add test code about SetOption in toeknERC20.test
Signed-off-by: 5pecia1 <pdpxpd@gmail.com>
2021-01-13 00:53:46 -05:00
Julian Castrence
1829666e3a Rename token-account-based Directory to token-erc-20
FAB-18275

Signed-off-by: Julian Castrence <juliancastrence@ibm.com>
2020-11-21 11:08:18 -05:00