Skip to content

Commit

Permalink
Remove unnecessary database instances
Browse files Browse the repository at this point in the history
  • Loading branch information
JSKitty committed Jul 7, 2023
1 parent 7f45d07 commit 9e123ce
Showing 1 changed file with 0 additions and 3 deletions.
3 changes: 0 additions & 3 deletions scripts/global.js
Original file line number Diff line number Diff line change
Expand Up @@ -1873,8 +1873,6 @@ async function renderProposals(arrProposals, fContested) {
const cMasternode = await database.getMasternode();

if (!fContested) {
const database = await Database.getInstance();

const localProposals =
(await database.getAccount())?.localProposals?.map((p) => {
return {
Expand Down Expand Up @@ -1951,7 +1949,6 @@ async function renderProposals(arrProposals, fContested) {
const result = await Masternode.finalizeProposal(cProposal.mpw);
const deleteProposal = async () => {
// Remove local Proposal from local storage
const database = await Database.getInstance();
const account = await database.getAccount();
const localProposals = account?.localProposals || [];
await database.addAccount({
Expand Down

0 comments on commit 9e123ce

Please sign in to comment.