From 95cc2bb14db91350be267de6136d4902d74c5d30 Mon Sep 17 00:00:00 2001 From: Akinwale Ariwodola Date: Sun, 26 May 2019 09:45:56 +0100 Subject: [PATCH] add parseFloat for costInfo.cost --- src/redux/actions/file.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/redux/actions/file.js b/src/redux/actions/file.js index 28ccf39..50f318f 100644 --- a/src/redux/actions/file.js +++ b/src/redux/actions/file.js @@ -89,7 +89,7 @@ export function doPurchaseUri(uri: string, costInfo: { cost: number }, saveFile: const { cost } = costInfo; - if (cost > balance) { + if (parseFloat(cost) > balance) { dispatch({ type: ACTIONS.PURCHASE_URI_FAILED, data: { uri, error: 'Insufficient credits' },