utils

package
v0.0.0-...-694d7ce Latest Latest
Warning

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

Go to latest
Published: Nov 13, 2020 License: MPL-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Version = "3.0.0b1"

Version defines the bots version.

Functions

func FindDefaultChannel

func FindDefaultChannel(guild *discordgo.Guild) string

FindDefaultChannel is used to find the default channel to post the first message.

func ProcessMemberArg

func ProcessMemberArg(Channel *discordgo.Channel, Session *discordgo.Session, Arg string) *discordgo.Member

ProcessMemberArg is used to process a member argument and throw an error if needed.

func SpaceSplit

func SpaceSplit(Data string) []string

SpaceSplit splits a string by the SPACE character, but does take into account multiple spaces.

Types

type Mention

type Mention struct {
	Len int
	ID  string
}

Mention is the user mention specified.

func CheckMention

func CheckMention(Content string, OtherID *string) *Mention

CheckMention is used to check if the bot was mentioned.

Jump to

Keyboard shortcuts

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