Преглед на файлове

Add GetEngine method for websubsvc ctx.

ZRY преди 4 месеца
родител
ревизия
aa9dc45425
променени са 1 файла, в които са добавени 4 реда и са изтрити 0 реда
  1. 4 0
      websubsvc/webctx.go

+ 4 - 0
websubsvc/webctx.go

@@ -32,6 +32,10 @@ func (c *WebSubServiceContext) GetRootRouter() *gin.RouterGroup {
 	return &c.s.ginEngine.RouterGroup
 }
 
+func (c *WebSubServiceContext) GetEngine() *gin.Engine {
+	return c.s.ginEngine
+}
+
 // DefaultMiddleware will call EnableLogger and EnableRecovery
 func (c *WebSubServiceContext) DefaultMiddleware(logPrefix, recoveryLogPrefix string) {
 	c.EnableLogger(logPrefix)