mirror of
https://github.com/henrygd/beszel.git
synced 2025-12-17 02:36:17 +01:00
Refactor hub initialization and error handling
This commit is contained in:
@@ -5,6 +5,7 @@ import (
|
||||
"beszel/internal/hub"
|
||||
_ "beszel/migrations"
|
||||
"fmt"
|
||||
"log"
|
||||
"net/http"
|
||||
"os"
|
||||
"time"
|
||||
@@ -27,8 +28,9 @@ func main() {
|
||||
|
||||
baseApp := getBaseApp()
|
||||
h := hub.NewHub(baseApp)
|
||||
h.BootstrapHub()
|
||||
h.Start()
|
||||
if err := h.StartHub(); err != nil {
|
||||
log.Fatal(err)
|
||||
}
|
||||
}
|
||||
|
||||
// getBaseApp creates a new PocketBase app with the default config
|
||||
|
||||
Reference in New Issue
Block a user