Removed secret field from types.ShortenReq

This commit is contained in:
2022-08-27 14:02:33 +02:00
parent bf770ee0db
commit 03d845b00d
5 changed files with 2 additions and 7 deletions

View File

@ -4,7 +4,7 @@ import "github.com/scylladb/gocqlx/v2/table"
var UrlTable = table.New(table.Metadata{
Name: "fivefeeteleven.urls",
Columns: []string{"id", "redirect_url", "secret"},
Columns: []string{"id", "redirect_url"},
PartKey: []string{"id"},
SortKey: []string{},
})
@ -12,5 +12,4 @@ var UrlTable = table.New(table.Metadata{
type UrlModel struct {
Id string
RedirectUrl string
Secret *string
}

View File

@ -15,8 +15,7 @@ func Seed(session gocqlx.Session) error {
err = session.ExecStmt(`
CREATE TABLE IF NOT EXISTS fivefeeteleven.urls (
id text PRIMARY KEY,
redirect_url text,
secret text
redirect_url text
)`)
if err != nil {