email

package
v0.19.0 Latest Latest
Warning

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

Go to latest
Published: Aug 14, 2021 License: AGPL-3.0 Imports: 7 Imported by: 3

Documentation

Index

Constants

This section is empty.

Variables

View Source
var NoReply = env.Config.Email.NoReply

NoReply is the default 'from' address

Functions

func CanSendTo

func CanSendTo(address string) bool

CanSendTo returns true if Fider is allowed to send email to given address

func SetAllowlist

func SetAllowlist(s string)

SetAllowlist can be used to change email allowlist during runtime

func SetBlocklist

func SetBlocklist(s string)

SetBlocklist can be used to change email blocklist during runtime

Types

type Message

type Message struct {
	Subject string
	Body    string
}

Message represents what is sent by email

func RenderMessage

func RenderMessage(ctx context.Context, templateName string, params dto.Props) *Message

RenderMessage returns the HTML of an email based on template and params

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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