lib

package
v0.0.0-...-77f848b Latest Latest
Warning

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

Go to latest
Published: Sep 14, 2022 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrRecoverFromPanic = errors.New("recover from panic")
)

Functions

func SafeGo

func SafeGo(fn func())

SafeGo spawns a go-routine to run {#fn} with panic handler.

func Try

func Try(fn func()) (err error)

Try invokes #{fn} with panic handler. If #{fn} causes a panic, #{ErrRecoverFromPanic} will be returned. Otherwise, nil will be returned.

Types

type Webhook

type Webhook struct {
	// contains filtered or unexported fields
}

func GetWebhook

func GetWebhook(conf *setting.AppSetting) *Webhook

func (*Webhook) Execute

func (w *Webhook) Execute(message *setting.MessageSetting) error

Jump to

Keyboard shortcuts

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