mirror of https://github.com/status-im/migrate.git
Add NewDB to spanner.go
This commit is contained in:
parent
2fc1610248
commit
ca888b96e3
|
@ -55,6 +55,13 @@ type DB struct {
|
|||
data *spanner.Client
|
||||
}
|
||||
|
||||
func NewDB(admin sdb.DatabaseAdminClient, data spanner.Client) *DB {
|
||||
return &DB{
|
||||
admin: &admin,
|
||||
data: &data,
|
||||
}
|
||||
}
|
||||
|
||||
// WithInstance implements database.Driver
|
||||
func WithInstance(instance *DB, config *Config) (database.Driver, error) {
|
||||
if config == nil {
|
||||
|
|
Loading…
Reference in New Issue