mirror of
https://github.com/pocket-id/pocket-id.git
synced 2026-02-07 11:38:27 +00:00
refactor: replace create-one-time-access-token script with in-app functionality (#540)
This commit is contained in:
committed by
Elias Schneider
parent
35b227cd17
commit
cb2a9f9f7d
@@ -27,7 +27,7 @@ func Bootstrap() error {
|
||||
}
|
||||
|
||||
// Connect to the database
|
||||
db := newDatabase()
|
||||
db := NewDatabase()
|
||||
|
||||
// Create all services
|
||||
svc, err := initServices(ctx, db, httpClient)
|
||||
|
||||
@@ -23,7 +23,7 @@ import (
|
||||
"github.com/pocket-id/pocket-id/backend/resources"
|
||||
)
|
||||
|
||||
func newDatabase() (db *gorm.DB) {
|
||||
func NewDatabase() (db *gorm.DB) {
|
||||
db, err := connectDatabase()
|
||||
if err != nil {
|
||||
log.Fatalf("failed to connect to database: %v", err)
|
||||
|
||||
Reference in New Issue
Block a user