bindSQLApi registers the SQL api endpoints.
(app core.App, rg *router.RouterGroup[*core.RequestEvent])
| 20 | |
| 21 | // bindSQLApi registers the SQL api endpoints. |
| 22 | func bindSQLApi(app core.App, rg *router.RouterGroup[*core.RequestEvent]) { |
| 23 | subGroup := rg.Group("/sql").Bind(RequireSuperuserAuth()) |
| 24 | subGroup.POST("", runSQL) |
| 25 | } |
| 26 | |
| 27 | func runSQL(e *core.RequestEvent) error { |
| 28 | // extra precaution in case manually invoked from somewhere else |
no test coverage detected
searching dependent graphs…