model

package
v0.1.7 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 15, 2022 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Notification

type Notification struct {
	Uuid             string           `json:"uuid"`
	User             User             `json:"user"`
	Seen             bool             `json:"seen"`
	Link             string           `json:"link"`
	NotificationType NotificationType `json:"notificationType,omitempty"`
	TriggeredByUser  User             `json:"triggered_by_user,omitempty"`
}

type NotificationType

type NotificationType string
const (
	LIKED    NotificationType = "liked"
	FOLLOWED NotificationType = "followed"
	REPLIED  NotificationType = "replied"
)

List of NotificationType

type User

type User struct {
	Uuid       string `json:"uuid"`
	Username   string `json:"username,omitempty"`
	Name       string `json:"name,omitempty"`
	ProfilePic string `json:"profile_pic,omitempty"`
	IsBanned   bool   `json:"is_banned,omitempty"`
}

func DecodeMessageToUser

func DecodeMessageToUser(message []byte) (*User, error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL