Skip to content

Commit

Permalink
Revert unintended avatar stock checker
Browse files Browse the repository at this point in the history
This reverts a feature accidentally introduced by #296 where every
user's avatar in the queue would be checked if it was a stock avatar.
  • Loading branch information
KevSlashNull committed Dec 10, 2024
1 parent ce8e1e0 commit a13e3f5
Showing 1 changed file with 2 additions and 16 deletions.
18 changes: 2 additions & 16 deletions web/admin/pages/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -25,32 +25,18 @@ const actorProfilesMap = computed(() => {
return map;
});
const avatarStockMap = ref(new Map<string, boolean>());
watch(actorProfiles, async () => {
for (const profile of actorProfiles.value) {
const { isStockAvatar } = await fetch(
`https://bsky-cdn.codingpa.ws/avatar/${profile.did}/info.json`
).then((r) => r.json());
avatarStockMap.value.set(profile.did, isStockAvatar);
}
});
const queues = computed(() => ({
All: actors.value,
"Probably furry": actors.value.filter((actor) => {
const profile = didToProfile(actor.did);
return isProbablyFurry(profile) && !avatarStockMap.value.get(actor.did);
return isProbablyFurry(profile);
}),
"Empty profiles": actors.value.filter((actor) => {
const profile = didToProfile(actor.did);
if (!profile) return false;
return (
(!profile.displayName && !profile.description && !profile.postsCount) ||
avatarStockMap.value.get(actor.did)
);
return !profile.displayName && !profile.description && !profile.postsCount;
}),
"Held back": heldBack.value,
}));
Expand Down

0 comments on commit a13e3f5

Please sign in to comment.