MCPcopy Create free account
hub / github.com/1Panel-dev/1Panel / parseOpenclawSessionCount

Function parseOpenclawSessionCount

agent/app/service/agents_overview.go:161–170  ·  view source on GitHub ↗
(output string)

Source from the content-addressed store, hash-verified

159}
160
161func parseOpenclawSessionCount(output string) (int, error) {
162 if strings.TrimSpace(output) == "" {
163 return 0, nil
164 }
165 var payload interface{}
166 if err := json.Unmarshal([]byte(strings.TrimSpace(output)), &payload); err != nil {
167 return 0, err
168 }
169 return countOpenclawSessions(payload), nil
170}
171
172func parseOpenclawCronCount(output string) (int, error) {
173 if strings.TrimSpace(output) == "" {

Callers 1

Calls 1

countOpenclawSessionsFunction · 0.85

Tested by

no test coverage detected