Merge pull request #77 from lsmelan/lsmelan-patch-1

Fix: issue #71
This commit is contained in:
Kuan-Cheng,Lai 2018-05-18 12:01:26 +08:00 committed by GitHub
commit 831d2ebdbe
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -77,7 +77,7 @@ class Str extends SolidityType implements IType
public function outputFormat($value, $name)
{
$strLen = mb_substr($value, 0, 64);
$strValue = mb_substr($value, 64, 64);
$strValue = mb_substr($value, 64);
$match = [];
if (preg_match('/^[0]+([a-f0-9]+)$/', $strLen, $match) === 1) {
@ -87,4 +87,4 @@ class Str extends SolidityType implements IType
return Utils::hexToBin($strValue);
}
}
}