fix: rename ddl assets

This commit is contained in:
Markus Pesch 2021-04-06 19:40:56 +02:00
parent a48ae72b4b
commit 8c2090a316
Signed by: volker.raschek
GPG Key ID: 852BCC170D81A982
2 changed files with 4 additions and 4 deletions

View File

@ -17,7 +17,7 @@ import (
var (
//go:embed ddl/*.sql
postgresDDLAssets embed.FS
ddlAssets embed.FS
//go:embed dml/deleteDeviceByID.sql
deleteDeviceByIDSQL string
@ -470,7 +470,7 @@ func (postgres *Postgres) Close() error {
// Migrate creates all required tables if not exist
func (postgres *Postgres) Migrate(ctx context.Context) error {
sourceDriver, err := iofs.New(postgresDDLAssets, "ddl")
sourceDriver, err := iofs.New(ddlAssets, "ddl")
if err != nil {
return err
}

View File

@ -19,7 +19,7 @@ import (
var (
//go:embed ddl/*.sql
sqlite3DDLAssets embed.FS
ddlAssets embed.FS
//go:embed dml/deleteDeviceByID.sql
deleteDeviceByIDSQL string
@ -462,7 +462,7 @@ func (sqlite *SQLite) Migrate(ctx context.Context) error {
sqlite.mutex.Lock()
defer sqlite.mutex.Unlock()
sourceDriver, err := iofs.New(sqlite3DDLAssets, "ddl")
sourceDriver, err := iofs.New(ddlAssets, "ddl")
if err != nil {
return err
}