Improved code documentation

This commit is contained in:
2019-09-10 09:49:51 +09:00
parent e774dccb08
commit 27753f6f9e
11 changed files with 28 additions and 24 deletions

View File

@ -8,13 +8,13 @@ func init() {
}
}
// AnimeCharacter ...
// AnimeCharacter contains the information for a character and his role in an anime.
type AnimeCharacter struct {
CharacterID string `json:"characterId" editable:"true"`
Role string `json:"role" editable:"true" datalist:"anime-character-roles"`
}
// Character ...
// Character returns the referenced character.
func (char *AnimeCharacter) Character() *Character {
character, _ := GetCharacter(char.CharacterID)
return character