Skip to content

Commit

Permalink
Merge pull request #22 from MarvNC/remove-needsStructuredContent
Browse files Browse the repository at this point in the history
Remove Unused `needsStructuredContent` Function
  • Loading branch information
MarvNC authored Jul 11, 2024
2 parents 87634a4 + 8bdbda4 commit 1a7618b
Showing 1 changed file with 0 additions and 21 deletions.
21 changes: 0 additions & 21 deletions jmdict_glossary.go
Original file line number Diff line number Diff line change
Expand Up @@ -168,27 +168,6 @@ func listAttr(lang string, listStyleType string, dataContent string) contentAttr
}
}

func needsStructuredContent(sense jmdict.JmdictSense, language string) bool {
for _, gloss := range sense.Glossary {
if glossContainsLanguage(gloss, language) && gloss.Type != nil {
return true
}
}
if len(sense.SourceLanguages) > 0 {
return true
} else if len(sense.Information) > 0 {
return true
} else if len(sense.Antonyms) > 0 {
return true
} else if len(sense.References) > 0 {
return true
} else if len(sense.Examples) > 0 {
return true
} else {
return false
}
}

func createGlossaryContent(sense jmdict.JmdictSense, meta jmdictMetadata) any {
glossaryContents := []any{}

Expand Down

0 comments on commit 1a7618b

Please sign in to comment.