From 3a57279e3300b250ac2a80e1bc236b9302c8b039 Mon Sep 17 00:00:00 2001 From: Pierrick TURELIER Date: Wed, 31 Jul 2019 16:03:47 +0200 Subject: [PATCH] Fix contract_owner_button onClick indentation --- app/assets/v2/js/grants/detail.js | 54 +++++++++++++++---------------- 1 file changed, 26 insertions(+), 28 deletions(-) diff --git a/app/assets/v2/js/grants/detail.js b/app/assets/v2/js/grants/detail.js index 3ebe4e85b66..5f5dc720ae5 100644 --- a/app/assets/v2/js/grants/detail.js +++ b/app/assets/v2/js/grants/detail.js @@ -178,35 +178,33 @@ $(document).ready(function() { let deployedSubscription = new web3.eth.Contract(compiledSubscription.abi, contract_address); web3.eth.getAccounts(function(err, accounts) { - deployedSubscription.methods - .changeOwnership(contract_owner_address) - .send({ - from: accounts[0], - gasPrice: 8000000000 - }) - .on('transactionHash', function(transactionHash) { - const linkURL = get_etherscan_url(transactionHash); - - document.issueURL = linkURL; - $('#transaction_url').attr('href', linkURL); - $('.modal .close').trigger('click'); - enableWaitState('#grants-details'); - }) - .on('confirmation', function(confirmationNumber, receipt) { - $.ajax({ - type: 'post', - url: '', - data: { - 'contract_owner_address': contract_owner_address - }, - success: function(json) { - window.location.reload(false); - }, - error: function() { - _alert({ message: gettext('Changing the contract owner address failed to save. Please try again.') }, 'error'); - } - }); + deployedSubscription.methods.changeOwnership( + contract_owner_address + ).send({ + from: accounts[0], + gasPrice: 8000000000 + }).on('transactionHash', function(transactionHash) { + const linkURL = get_etherscan_url(transactionHash); + + document.issueURL = linkURL; + $('#transaction_url').attr('href', linkURL); + $('.modal .close').trigger('click'); + enableWaitState('#grants-details'); + }).on('confirmation', function(confirmationNumber, receipt) { + $.ajax({ + type: 'post', + url: '', + data: { + 'contract_owner_address': contract_owner_address + }, + success: function(json) { + window.location.reload(false); + }, + error: function() { + _alert({ message: gettext('Changing the contract owner address failed to save. Please try again.') }, 'error'); + } }); + }); }); });