Client - display only user sports in stats labels

This commit is contained in:
Sam 2021-10-04 09:22:15 +02:00
parent 1502e97211
commit f328e632ac

View File

@ -25,8 +25,10 @@
const authUser: ComputedRef<IAuthUserProfile> = computed( const authUser: ComputedRef<IAuthUserProfile> = computed(
() => store.getters[USER_STORE.GETTERS.AUTH_USER_PROFILE] () => store.getters[USER_STORE.GETTERS.AUTH_USER_PROFILE]
) )
const sports: ComputedRef<ISport[]> = computed( const sports: ComputedRef<ISport[]> = computed(() =>
() => store.getters[SPORTS_STORE.GETTERS.SPORTS] store.getters[SPORTS_STORE.GETTERS.SPORTS].filter((sport) =>
authUser.value.sports_list.includes(sport.id)
)
) )
return { authUser, sports } return { authUser, sports }
}, },