fix: i have taken over and implemented the proposals from tirrok

This commit is contained in:
ogerly 2020-08-04 13:08:11 +02:00
parent 9b14a5327a
commit 1c1a0030f7
2 changed files with 6 additions and 8 deletions

View File

@ -15,9 +15,9 @@
$t( $t(
'settings.deleteUserAccount.contributionsCount', 'settings.deleteUserAccount.contributionsCount',
{ {
count: currentUserCount.contributionsCount, count: currentUserCounts.contributionsCount,
}, },
currentUserCount.contributionsCount, currentUserCounts.contributionsCount,
) )
}} }}
</label> </label>
@ -27,9 +27,9 @@
$t( $t(
'settings.deleteUserAccount.commentedCount', 'settings.deleteUserAccount.commentedCount',
{ {
count: currentUserCount.commentedCount, count: currentUserCounts.commentedCount,
}, },
currentUserCount.commentedCount, currentUserCounts.commentedCount,
) )
}} }}
</label> </label>
@ -61,7 +61,7 @@ export default {
deleteContributions: false, deleteContributions: false,
deleteComments: false, deleteComments: false,
enableDeletionValue: null, enableDeletionValue: null,
currentUserCount: [], currentUserCounts: {},
} }
}, },
apollo: { apollo: {
@ -70,7 +70,7 @@ export default {
return currentUserCountQuery() return currentUserCountQuery()
}, },
update(currentUser) { update(currentUser) {
this.currentUserCount = currentUser.currentUser this.currentUserCounts = currentUser.currentUser
}, },
}, },
}, },

View File

@ -265,11 +265,9 @@ export const checkSlugAvailableQuery = gql`
export const currentUserQuery = gql` export const currentUserQuery = gql`
${userFragment} ${userFragment}
${userCountsFragment}
query { query {
currentUser { currentUser {
...user ...user
...userCounts
email email
role role
about about