fix golint errors
This commit is contained in:
parent
fde49fefcf
commit
fc04e7ea13
|
@ -1,5 +1,7 @@
|
|||
# Hermes
|
||||
|
||||
[![Go Report Card](https://goreportcard.com/badge/github.com/matcornic/hermes)](https://goreportcard.com/report/github.com/matcornic/hermes)
|
||||
|
||||
Hermes is the Go port of the great [mailgen](https://github.com/eladnava/mailgen) engine for Node.js. Check their work, it's awesome !
|
||||
It's a package that generates clean, responsive HTML e-mails for sending transactional e-mails (welcome e-mail, reset password e-mails, receipt e-mails and so on).
|
||||
|
||||
|
|
|
@ -6,7 +6,7 @@ import (
|
|||
"io/ioutil"
|
||||
)
|
||||
|
||||
type Example interface {
|
||||
type example interface {
|
||||
Email() hermes.Email
|
||||
Name() string
|
||||
}
|
||||
|
@ -20,7 +20,7 @@ func main() {
|
|||
},
|
||||
}
|
||||
|
||||
examples := []Example{
|
||||
examples := []example{
|
||||
new(Welcome),
|
||||
new(Reset),
|
||||
new(Receipt),
|
||||
|
|
|
@ -4,14 +4,14 @@ import (
|
|||
"github.com/matcornic/hermes"
|
||||
)
|
||||
|
||||
type Receipt struct {
|
||||
type receipt struct {
|
||||
}
|
||||
|
||||
func (r *Receipt) Name() string {
|
||||
func (r *receipt) Name() string {
|
||||
return "receipt"
|
||||
}
|
||||
|
||||
func (r *Receipt) Email() hermes.Email {
|
||||
func (r *receipt) Email() hermes.Email {
|
||||
return hermes.Email{
|
||||
Body: hermes.Body{
|
||||
Name: "Jon Snow",
|
||||
|
|
|
@ -4,14 +4,14 @@ import (
|
|||
"github.com/matcornic/hermes"
|
||||
)
|
||||
|
||||
type Reset struct {
|
||||
type reset struct {
|
||||
}
|
||||
|
||||
func (r *Reset) Name() string {
|
||||
func (r *reset) Name() string {
|
||||
return "reset"
|
||||
}
|
||||
|
||||
func (r *Reset) Email() hermes.Email {
|
||||
func (r *reset) Email() hermes.Email {
|
||||
return hermes.Email{
|
||||
Body: hermes.Body{
|
||||
Name: "Jon Snow",
|
||||
|
|
|
@ -4,14 +4,14 @@ import (
|
|||
"github.com/matcornic/hermes"
|
||||
)
|
||||
|
||||
type Welcome struct {
|
||||
type welcome struct {
|
||||
}
|
||||
|
||||
func (w *Welcome) Name() string {
|
||||
func (w *welcome) Name() string {
|
||||
return "welcome"
|
||||
}
|
||||
|
||||
func (w *Welcome) Email() hermes.Email {
|
||||
func (w *welcome) Email() hermes.Email {
|
||||
return hermes.Email{
|
||||
Body: hermes.Body{
|
||||
Name: "Jon Snow",
|
||||
|
|
|
@ -48,7 +48,7 @@ type Email struct {
|
|||
type Body struct {
|
||||
Name string // The name of the contacted person
|
||||
Intros []string // Intro sentences, first displayed in the email
|
||||
Dictionary []Entry // A list of key+value (usefull for displaying parameters/settings/personal info)
|
||||
Dictionary []Entry // A list of key+value (useful for displaying parameters/settings/personal info)
|
||||
Table Table // Table is an table where you can put data (pricing grid, a bill, and so on)
|
||||
Actions []Action // Actions are a list of actions that the user will be able to execute via a button click
|
||||
Outros []string // Outro sentences, last displayed in the email
|
||||
|
|
Loading…
Reference in New Issue