mirror of
https://github.com/hugmouse/maddy-password-reset.git
synced 2025-04-19 13:00:26 +00:00
format using go fmt
This commit is contained in:
parent
7d4a9f82c3
commit
93b5066af8
1 changed files with 44 additions and 44 deletions
12
main.go
12
main.go
|
@ -4,10 +4,15 @@ import (
|
||||||
cryptorand "crypto/rand"
|
cryptorand "crypto/rand"
|
||||||
"database/sql"
|
"database/sql"
|
||||||
"fmt"
|
"fmt"
|
||||||
|
"github.com/akyoto/cache"
|
||||||
|
"github.com/hugmouse/maddy-password-reset/templates"
|
||||||
|
"github.com/labstack/echo/v4"
|
||||||
|
"github.com/labstack/echo/v4/middleware"
|
||||||
"html/template"
|
"html/template"
|
||||||
"io"
|
"io"
|
||||||
"log"
|
"log"
|
||||||
"math/big"
|
"math/big"
|
||||||
|
_ "modernc.org/sqlite"
|
||||||
"net/http"
|
"net/http"
|
||||||
"net/mail"
|
"net/mail"
|
||||||
"net/smtp"
|
"net/smtp"
|
||||||
|
@ -15,11 +20,6 @@ import (
|
||||||
"strconv"
|
"strconv"
|
||||||
"strings"
|
"strings"
|
||||||
"time"
|
"time"
|
||||||
_ "modernc.org/sqlite"
|
|
||||||
"github.com/akyoto/cache"
|
|
||||||
"github.com/hugmouse/maddy-password-reset/templates"
|
|
||||||
"github.com/labstack/echo/v4"
|
|
||||||
"github.com/labstack/echo/v4/middleware"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
@ -182,7 +182,7 @@ func main() {
|
||||||
if err != nil {
|
if err != nil {
|
||||||
log.Println("[AddressParser]: Invalid mail address: ", err)
|
log.Println("[AddressParser]: Invalid mail address: ", err)
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
go func() {
|
go func() {
|
||||||
// Check if there is already a password reset
|
// Check if there is already a password reset
|
||||||
_, exists := passwordResetCache.Get(mail)
|
_, exists := passwordResetCache.Get(mail)
|
||||||
|
|
Loading…
Add table
Reference in a new issue