go-crm initial
This commit is contained in:
@@ -5,8 +5,6 @@ import (
|
||||
"net/http"
|
||||
"time"
|
||||
|
||||
"go-crm/internal/db"
|
||||
|
||||
"github.com/go-chi/chi/v5"
|
||||
"golang.org/x/crypto/bcrypt"
|
||||
)
|
||||
@@ -61,7 +59,7 @@ func Signup(w http.ResponseWriter, r *http.Request) {
|
||||
CreatedAt: time.Now().Unix(),
|
||||
}
|
||||
|
||||
_, err = db.DB.Exec(
|
||||
_, err = DB.Exec(
|
||||
"INSERT INTO accounts (email, name, password, created_at) VALUES (?, ?, ?, ?)",
|
||||
account.Email, account.Name, account.Password, account.CreatedAt,
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user