Skip to content

Commit

Permalink
fix: remove unused attempt for account names counter (#600)
Browse files Browse the repository at this point in the history
  • Loading branch information
janmichek authored Dec 12, 2023
1 parent c15ebb6 commit 365b494
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 21 deletions.
11 changes: 0 additions & 11 deletions src/components/AccountDetailsPanel.vue
Original file line number Diff line number Diff line change
Expand Up @@ -61,17 +61,6 @@
{{ formatNumber(accountDetails.totalTransactionsCount) }}
</td>
</tr>
<tr class="account-details-panel__row">
<th class="account-details-panel__table-header">
AENS Names
<hint-tooltip>
{{ accountHints.aensNames }}
</hint-tooltip>
</th>
<td class="account-details-panel__data">
{{ formatNumber(accountDetails.namesCount) }}
</td>
</tr>
<tr
v-if="accountDetails.isGeneralized"
class="account-details-panel__row">
Expand Down
9 changes: 0 additions & 9 deletions src/stores/accountDetails.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ export const useAccountStore = defineStore('account', () => {

const rawAccountDetails = ref(null)
const totalAccountTransactionsCount = ref(null)
const accountNamesCount = ref(null)
const selectedKeyblock = ref(null)
const selectedMicroblock = ref(null)
const selectedKeyblockMicroblocks = ref(null)
Expand All @@ -34,7 +33,6 @@ export const useAccountStore = defineStore('account', () => {
...rawAccountDetails.value,
balance: formatAettosToAe(rawAccountDetails.value.balance),
totalTransactionsCount: totalAccountTransactionsCount.value,
namesCount: accountNamesCount.value,
isGeneralized: rawAccountDetails.value.kind === 'generalized',
}
: null,
Expand Down Expand Up @@ -70,7 +68,6 @@ export const useAccountStore = defineStore('account', () => {
fetchAccountTransactions({ accountId, limit }),
fetchTotalAccountTransactionsCount(accountId),
fetchAccountNames({ accountId, limit }),
fetchAccountNamesCount(accountId),
fetchAccountActivities({ accountId, limit }),
]),
])
Expand Down Expand Up @@ -126,11 +123,6 @@ export const useAccountStore = defineStore('account', () => {
)
}

async function fetchAccountNamesCount(accountId) {
const { data } = await axios.get(`${MIDDLEWARE_URL}/v2/names?owned_by=${accountId}&state=active`)
accountNamesCount.value = data.data.length
}

async function fetchAccountActivities({ accountId, limit, queryParameters } = {}) {
rawAccountActivities.value = null
const defaultParameters = `/v2/accounts/${accountId}/activities?limit=${limit ?? 10}`
Expand Down Expand Up @@ -166,7 +158,6 @@ export const useAccountStore = defineStore('account', () => {
return {
rawAccountDetails,
totalAccountTransactionsCount,
accountNamesCount,
selectedKeyblock,
selectedMicroblock,
selectedKeyblockMicroblocks,
Expand Down
1 change: 0 additions & 1 deletion src/utils/hints/accountHints.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ export const accountHints = {
balance: 'Amount of AE owned by the account.',
value: 'USD value of AE owned by the account.',
transactions: 'Amount of transactions where the account was involved.',
aensNames: 'Amount of names owned by the account.',
nonce: 'The nonce that was used to execute the last transaction for the account. The nonce is used to prevent replay attacks and keep transactions in order. If a transaction with a way higher nonce is broadcasted, it won\'t be executed until all transactions with lower nonces are executed.',
contractId: 'The contract that is attached to the account to create generalized account and takes over its authorization logic.',
apiLinks: 'Node API link of the account.',
Expand Down

0 comments on commit 365b494

Please sign in to comment.