fix/typo in func name CreateCustomer

This commit is contained in:
itsscb 2023-09-18 15:16:05 +02:00
parent b1cf768d9e
commit ea1b6047ee
2 changed files with 5 additions and 5 deletions

View File

@ -2,7 +2,7 @@
SELECT * FROM customers SELECT * FROM customers
WHERE "ID" = $1 LIMIT 1; WHERE "ID" = $1 LIMIT 1;
-- name: CreateCutomer :one -- name: CreateCustomer :one
INSERT INTO customers ( INSERT INTO customers (
username, username,
passwordhash, passwordhash,

View File

@ -11,7 +11,7 @@ import (
"time" "time"
) )
const createCutomer = `-- name: CreateCutomer :one const createCustomer = `-- name: CreateCustomer :one
INSERT INTO customers ( INSERT INTO customers (
username, username,
passwordhash, passwordhash,
@ -31,7 +31,7 @@ INSERT INTO customers (
) RETURNING "ID", username, passwordhash, firstname, lastname, birthday, "privacyAccepted", "privacyAcceptedDate", email, phone, city, zip, street, country, token, "tokenValid", "tokenExpiration", creator, created, changer, changed ) RETURNING "ID", username, passwordhash, firstname, lastname, birthday, "privacyAccepted", "privacyAcceptedDate", email, phone, city, zip, street, country, token, "tokenValid", "tokenExpiration", creator, created, changer, changed
` `
type CreateCutomerParams struct { type CreateCustomerParams struct {
Username string `json:"username"` Username string `json:"username"`
Passwordhash string `json:"passwordhash"` Passwordhash string `json:"passwordhash"`
Firstname string `json:"firstname"` Firstname string `json:"firstname"`
@ -47,8 +47,8 @@ type CreateCutomerParams struct {
Changer string `json:"changer"` Changer string `json:"changer"`
} }
func (q *Queries) CreateCutomer(ctx context.Context, arg CreateCutomerParams) (Customer, error) { func (q *Queries) CreateCustomer(ctx context.Context, arg CreateCustomerParams) (Customer, error) {
row := q.db.QueryRowContext(ctx, createCutomer, row := q.db.QueryRowContext(ctx, createCustomer,
arg.Username, arg.Username,
arg.Passwordhash, arg.Passwordhash,
arg.Firstname, arg.Firstname,