This repository has been archived on 2024-07-22. You can view files and clone it, but cannot push or open issues or pull requests.
otter-space-sdk/pkg/models/const.go
SoXX 76f3c8d97e refactor(model): changed types of model
Signed-off-by: SoXX <soxx@fenpa.ws>
2024-05-31 16:03:35 +02:00

31 lines
540 B
Go

package models
type AnthroveUserID string
type AnthrovePostID string
type AnthroveRating string
type AnthroveSourceDomain string
type AnthroveSourceIcon string
type AnthroveSourceDisplayName string
const (
SFW AnthroveRating = "s"
NSFW AnthroveRating = "e"
Questionable AnthroveRating = "q"
Unknown AnthroveRating = "unknown"
)
func (r *AnthroveRating) Convert(e621Rating string) {
switch e621Rating {
case "e":
*r = NSFW
case "q":
*r = Questionable
case "s":
*r = SFW
default:
*r = Unknown
}
}