MCPcopy Create free account
hub / github.com/couchbase/sync_gateway / shouldShowProductVersion

Method shouldShowProductVersion

rest/handler.go:1817–1820  ·  view source on GitHub ↗

shouldShowProductVersion returns whether the handler should show detailed product info (version). Admin requests can always see this, regardless of the HideProductVersion setting.

()

Source from the content-addressed store, hash-verified

1815// shouldShowProductVersion returns whether the handler should show detailed product info (version).
1816// Admin requests can always see this, regardless of the HideProductVersion setting.
1817func (h *handler) shouldShowProductVersion() bool {
1818 hideProductVersion := base.ValDefault(h.server.Config.API.HideProductVersion, false)
1819 return h.serverType == adminServer || !hideProductVersion
1820}
1821
1822func requiresWritePermission(accessPermissions []Permission) bool {
1823 for _, permission := range accessPermissions {

Callers 3

handleRootMethod · 0.95
handleGetStatusMethod · 0.95

Calls 1

ValDefaultFunction · 0.92

Tested by

no test coverage detected