aboutsummaryrefslogtreecommitdiffstats
path: root/ui/app/helpers/transactions.util.js
diff options
context:
space:
mode:
Diffstat (limited to 'ui/app/helpers/transactions.util.js')
-rw-r--r--ui/app/helpers/transactions.util.js5
1 files changed, 5 insertions, 0 deletions
diff --git a/ui/app/helpers/transactions.util.js b/ui/app/helpers/transactions.util.js
index 8ded31bca..e890a0852 100644
--- a/ui/app/helpers/transactions.util.js
+++ b/ui/app/helpers/transactions.util.js
@@ -14,6 +14,7 @@ import {
SEND_TOKEN_ACTION_KEY,
TRANSFER_FROM_ACTION_KEY,
SIGNATURE_REQUEST_KEY,
+ UNKNOWN_FUNCTION_KEY,
} from '../constants/transactions'
abiDecoder.addABI(abi)
@@ -56,6 +57,10 @@ export function getTransactionActionKey (transaction, methodData) {
const { name } = methodData
const methodName = name && name.toLowerCase()
+ if (!methodName) {
+ return UNKNOWN_FUNCTION_KEY
+ }
+
switch (methodName) {
case TOKEN_METHOD_TRANSFER:
return SEND_TOKEN_ACTION_KEY