Skip to content

Commit

Permalink
1.0.3
Browse files Browse the repository at this point in the history
  • Loading branch information
陈志同 committed Sep 12, 2018
1 parent d08455d commit 802628b
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 4 deletions.
2 changes: 0 additions & 2 deletions NeoContract/CGAS.cs
Original file line number Diff line number Diff line change
Expand Up @@ -284,8 +284,6 @@ private static bool Transfer(byte[] from, byte[] to, BigInteger amount, byte[] c
throw new InvalidOperationException("The parameters from and to SHOULD be 20-byte addresses.");
if (amount <= 0)
throw new InvalidOperationException("The parameter amount MUST be greater than 0.");
if (ExecutionEngine.EntryScriptHash.AsBigInteger() != callscript.AsBigInteger())
return false;
if (!IsPayable(to))
return false;
if (!Runtime.CheckWitness(from) && from.AsBigInteger() != callscript.AsBigInteger()) /*0.2*/
Expand Down
4 changes: 2 additions & 2 deletions UnitTests/CGASTest.cs
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@ namespace UnitTests
{
public static class CGASTest
{
static readonly UInt160 SgasAddress = Wallet.ToScriptHash("Ae8AD6Rc3cvQapqttJcUTj9ULfLi2tLHmc");
static readonly UInt160 ScriptHash = new UInt160("0x505663a29d83663a838eee091249abd167e928f5".Remove(0, 2).HexToBytes().Reverse().ToArray());
static readonly UInt160 CgasAddress = Wallet.ToScriptHash("AScKxyXmNtEnTLTvbVhNQyTJmgytxhwSnM");
static readonly UInt160 ScriptHash = new UInt160("0x74f2dc36a68fdc4682034178eb2220729231db76".Remove(0, 2).HexToBytes().Reverse().ToArray());
static readonly UInt160 User = Wallet.ToScriptHash("AJd31a8rYPEBkY1QSxpsGy8mdU4vTYTD4U");
static readonly byte[] UserScript = "2103ad1d70f140d84a90ad4491cdf175fa64bfa9287a006e8cbd8f8db8500b5205baac".HexToBytes();

Expand Down
20 changes: 20 additions & 0 deletions readme.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,25 @@
# CGAS

## Release Note:

**1.0.3** pre-release

Script Hash: 0x74f2dc36a68fdc4682034178eb2220729231db76

CGAS Contract Address: AScKxyXmNtEnTLTvbVhNQyTJmgytxhwSnM

**1.0.2**

Script Hash: [0x505663a29d83663a838eee091249abd167e928f5](https://neotracker.io/contract/505663a29d83663a838eee091249abd167e928f5)

CGAS Contract Address: Ae8AD6Rc3cvQapqttJcUTj9ULfLi2tLHmc

1.0.**1**

Script Hash: [0x9121e89e8a0849857262d67c8408601b5e8e0524](https://neotracker.io/contract/9121e89e8a0849857262d67c8408601b5e8e0524)

CGAS Contract Address: AK4LdT5ZXR9DQZjfk5X6Xy79mE8ad8jKAW

[English](#en) [简体中文](#zh)

<a name="en"></a>
Expand Down

0 comments on commit 802628b

Please sign in to comment.