mail

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Oct 6, 2022 License: AGPL-3.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrTemplateNotFound = errors.New("mail template not found")
)

Functions

func Disable

func Disable(t bool)

func Init

func Init(c *config.Config) error

func Send

func Send(to string, subject string, msgType string, args map[string]interface{}) error

func SetSender

func SetSender(s string)

Types

type Templates

type Templates struct {
	Text *text.Template
	HTML *html.Template
}

func (*Templates) RenderHTML

func (t *Templates) RenderHTML(tname string, args map[string]interface{}) (string, error)

func (*Templates) RenderText

func (t *Templates) RenderText(tname string, args map[string]interface{}) (string, error)

Jump to

Keyboard shortcuts

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