MCPcopy Create free account
hub / github.com/chainreactors/EvilProxy / managementAvailable

Method managementAvailable

internal/api/server.go:772–786  ·  view source on GitHub ↗
(c *gin.Context)

Source from the content-addressed store, hash-verified

770}
771
772func (s *Server) managementAvailable(c *gin.Context) bool {
773 if s == nil || s.cfg == nil {
774 c.AbortWithStatus(http.StatusNotFound)
775 return false
776 }
777 if s.cfg.Home.Enabled {
778 c.AbortWithStatus(http.StatusNotFound)
779 return false
780 }
781 if !s.managementRoutesEnabled.Load() {
782 c.AbortWithStatus(http.StatusNotFound)
783 return false
784 }
785 return true
786}
787
788func (s *Server) refreshPluginManagementRoutes() {
789 if s == nil || s.pluginHost == nil || s.engine == nil {

Callers 2

Calls 1

LoadMethod · 0.65

Tested by

no test coverage detected