diff --git a/supernode/cash_payments_handler.html b/supernode/cash_payments_handler.html index 913fc85..1e7aad5 100644 --- a/supernode/cash_payments_handler.html +++ b/supernode/cash_payments_handler.html @@ -95,6 +95,17 @@ unique: false }); } + if (!db.objectStoreNames.contains('supernodesList')) { + var objectStore = db.createObjectStore("supernodesList", { + keyPath: 'id' + }); + objectStore.createIndex('trader_flo_address', 'trader_flo_address', { + unique: true + }); + objectStore.createIndex('ip', 'ip', { + unique: false + }); + } } diff --git a/supernode/index.html b/supernode/index.html index 05af928..fa9f54c 100644 --- a/supernode/index.html +++ b/supernode/index.html @@ -10975,6 +10975,7 @@ reactor.registerEvent('switchToBackupWSForSuperNodesOperations'); reactor.registerEvent('user_flo_keys_active'); reactor.registerEvent('remove_extra_backup_connections'); + reactor.registerEvent('request_to_modify_user_balance_on_successfull_fiat_deposit'); reactor.addEventListener('fireNodeWelcomeBackEvent', function(evt) { let getFLOId = bitjs.FLO_TEST.pubkey2address(evt.flo_public_key); @@ -11475,6 +11476,18 @@ } }); + /*This function is used to verify a tx denoting token transfer by trusted guy to the supernode + and to increase balance of the respective user node.*/ + reactor.addEventListener('request_to_modify_user_balance_on_successfull_fiat_deposit', + function(token_transfer_resp) { + /* + token_transfer_resp = { + tx: ec289d40069bb4db8b633133560269004a35f834c4a146560887ac87f7789d35, + user_action: 'deposit' + } + */ + }); +