feat: inject runtime helpers to controllers and services

This commit is contained in:
Stavros
2026-06-21 13:00:36 +03:00
parent 23af559f2f
commit 474e297d9d
8 changed files with 25 additions and 0 deletions
+3
View File
@@ -28,6 +28,7 @@ type OAuthController struct {
config *model.Config
runtime *model.RuntimeConfig
auth *service.AuthService
helpers *model.RuntimeHelpers
}
type OAuthControllerInput struct {
@@ -36,6 +37,7 @@ type OAuthControllerInput struct {
Log *logger.Logger
Config *model.Config
RuntimeConfig *model.RuntimeConfig
Helpers *model.RuntimeHelpers
RouterGroup *gin.RouterGroup `name:"apiRouterGroup"`
AuthService *service.AuthService
}
@@ -46,6 +48,7 @@ func NewOAuthController(i OAuthControllerInput) *OAuthController {
config: i.Config,
runtime: i.RuntimeConfig,
auth: i.AuthService,
helpers: i.Helpers,
}
oauthGroup := i.RouterGroup.Group("/oauth")