next
neobooru 2021-06-13 17:07:28 +02:00
parent 1f719dc0cb
commit 4381b4ebbf
1 changed files with 3 additions and 9 deletions

View File

@ -341,22 +341,16 @@ export default Vue.extend({
.map((x) => encodeTagName(x.name)) .map((x) => encodeTagName(x.name))
.join(); .join();
const resp = await this.szuru?.getTags(query); const resp = await this.szuru?.getTags(query);
console.dir(resp);
if (resp) { if (resp) {
for (let post of this.posts) { for (let post of this.posts)
for (let tag of resp.results) { for (let tag of resp.results)
for (let postTag of post.tags) { for (let postTag of post.tags)
if (postTag.name == tag.names[0]) { if (postTag.name == tag.names[0]) {
postTag.usages = tag.usages; postTag.usages = tag.usages;
break; break;
} }
}
}
}
} }
console.dir(this.posts);
} }
}, },
}, },