Resolve public_base_url at SignURL time so admin settings apply without restart. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -24,20 +24,19 @@ type Service struct {
|
||||
db *gorm.DB
|
||||
cache *cache.Store
|
||||
images *imagestore.Store
|
||||
hub *Hub
|
||||
publicURL string
|
||||
waitSec int64
|
||||
hub *Hub
|
||||
waitSec int64
|
||||
mu sync.Mutex
|
||||
running map[string]context.CancelFunc
|
||||
}
|
||||
|
||||
func NewService(db *gorm.DB, c *cache.Store, images *imagestore.Store, publicURL string, waitSec int64) *Service {
|
||||
func NewService(db *gorm.DB, c *cache.Store, images *imagestore.Store, waitSec int64) *Service {
|
||||
if waitSec <= 0 {
|
||||
waitSec = 60
|
||||
}
|
||||
return &Service{
|
||||
db: db, cache: c, images: images, hub: NewHub(),
|
||||
publicURL: strings.TrimRight(publicURL, "/"), waitSec: waitSec,
|
||||
waitSec: waitSec,
|
||||
running: make(map[string]context.CancelFunc),
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user