CEP_Account.update()
With this method you can update the account parameters such as Nonce etc.
Function Signature
async update()
Parameters
Parameter Name
Datatype
Example (CommonJS)
const { CEP_Account } = require('circular-enterprise-apis');
const Address = 'your-wallet-address';
let account = new CEP_Account();
async function run() {
//...
const updateResult = await account.updateAccount();
console.log("Account updated");
if (!updateResult) {
console.log("Account Failed to Update");
return;
}
console.log("Account up to date");
console.log("Nonce : ", account.Nonce);
//...
}
run();
Example (ES Modules)
import { CEP_Account } from 'circular-enterprise-apis';
const Address = 'your-wallet-address';
let account = new CEP_Account();
async function run() {
//...
const updateResult = await account.updateAccount();
console.log("Account updated");
if (!updateResult) {
console.log("Account Failed to Update");
return;
}
console.log("Account up to date");
console.log("Nonce : ", account.Nonce);
//...
}
run();
Last updated