Skip to content

Commit

Permalink
Move pos and label tags to sense tags
Browse files Browse the repository at this point in the history
  • Loading branch information
MarvNC committed Feb 1, 2024
1 parent f4b70e8 commit a901970
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/util/yomitan/convertEntryToYomitanTerms.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,11 +33,10 @@ function convertEntryToYomitanTerms(dictionaryEntry) {
function addTagsToTermEntry(dictionaryEntry, termEntry) {
const termTags = [];
const entryTags = [];
const tagTypesToAdd = ['pos', 'label'];
for (const tag of dictionaryEntry.tags) {
if (tag.name === 'pos') {
if (tagTypesToAdd.includes(tag.name)) {
entryTags.push(tag.value);
} else if (tag.name === 'label') {
termTags.push(tag.value);
}
}
termEntry.setTermTags(termTags.join(' '));
Expand Down

0 comments on commit a901970

Please sign in to comment.