starboard

package
v0.0.0-...-ca060dc Latest Latest
Warning

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

Go to latest
Published: Dec 13, 2023 License: GPL-3.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

View Source
const Expiry = 48 * time.Hour

Starred messages expire after 2 days.

View Source
const MaxStarred = 200

Variables

This section is empty.

Functions

This section is empty.

Types

type GuildSettings

type GuildSettings struct {
	GuildID discord.GuildID

	WebhookID      discord.WebhookID
	WebhookToken   string
	WebhookChannel discord.ChannelID

	Starcount uint32
	Reaction  string

	Blacklisted []discord.ChannelID
}

type Starboard

type Starboard struct {
	Ctx *bot.Context
	// contains filtered or unexported fields
}

func New

func New(node db.Node) *Starboard

func (*Starboard) GetBlacklisted

func (s *Starboard) GetBlacklisted(m *gateway.MessageCreateEvent) error

func (*Starboard) GetReaction

func (s *Starboard) GetReaction(m *gateway.MessageCreateEvent) error

func (*Starboard) GetStarcount

func (s *Starboard) GetStarcount(m *gateway.MessageCreateEvent) error

func (*Starboard) Handler

func (*Starboard) Initialize

func (s *Starboard) Initialize(
	m *gateway.MessageCreateEvent, mention *arguments.ChannelMention) error

func (*Starboard) ResetMessage

func (s *Starboard) ResetMessage(
	m *gateway.MessageCreateEvent, msgID discord.Snowflake) error

func (*Starboard) SetReaction

func (s *Starboard) SetReaction(
	m *gateway.MessageCreateEvent, emoji string) error

func (*Starboard) SetStarcount

func (s *Starboard) SetStarcount(
	m *gateway.MessageCreateEvent, count uint32) error

func (*Starboard) Setup

func (s *Starboard) Setup(sub *bot.Subcommand)

func (*Starboard) ToggleBlacklisted

func (s *Starboard) ToggleBlacklisted(
	m *gateway.MessageCreateEvent, ch *arguments.ChannelMention) error

Jump to

Keyboard shortcuts

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