diff --git a/CHANGELOG.md b/CHANGELOG.md index f5b1719dd507..66458e2b5e93 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,10 @@ ## Current Develop Branch +## 0.6.5 Wed May 12 2021 + +- fix: internal contract get code (#335) + ## 0.6.4 Tue May 11 2021 - fix: use new phishing detect controller (#332) diff --git a/app/manifest.json b/app/manifest.json index ea08fb5b1e24..a7288e47b51f 100644 --- a/app/manifest.json +++ b/app/manifest.json @@ -1,7 +1,7 @@ { "name": "ConfluxPortal", "short_name": "ConfluxPortal", - "version": "0.6.4", + "version": "0.6.5", "manifest_version": 2, "author": "https://conflux-chain.org", "description": "__MSG_appDescription__", diff --git a/app/scripts/controllers/transactions/index.js b/app/scripts/controllers/transactions/index.js index 4178c078d49e..7391b5916a34 100644 --- a/app/scripts/controllers/transactions/index.js +++ b/app/scripts/controllers/transactions/index.js @@ -817,6 +817,20 @@ class TransactionController extends EventEmitter { */ async _determineTransactionCategory(txParams) { const { data, to } = txParams + + // detect internal contracts + if ( + [ + '0x0888000000000000000000000000000000000000', + '0x0888000000000000000000000000000000000001', + '0x0888000000000000000000000000000000000002', + ].includes(to?.toLowerCase()) + ) { + return { + transactionCategory: CONTRACT_INTERACTION_KEY, + getCodeResponse: to, + } + } const { name } = (data && abiDecoder.decodeMethod(data)) || {} const tokenMethodName = [ TOKEN_METHOD_APPROVE,