MCPcopy
hub / github.com/tailscale/tailscale / EqualBool

Method EqualBool

types/opt/bool.go:99–102  ·  view source on GitHub ↗

EqualBool reports whether b is equal to v. If b is empty or not a valid bool, it reports false.

(v bool)

Source from the content-addressed store, hash-verified

97// EqualBool reports whether b is equal to v.
98// If b is empty or not a valid bool, it reports false.
99func (b Bool) EqualBool(v bool) bool {
100 p, ok := b.Get()
101 return ok && p == v
102}
103
104var (
105 trueBytes = []byte(True)

Callers 15

TestBoolEqualBoolFunction · 0.80
TestInContainerFunction · 0.80
determineEndpointsMethod · 0.80
runSetFunction · 0.80
prefValueFunction · 0.80
portMappingFunction · 0.80
runFunction · 0.80
apiServerProxyServiceFunction · 0.80
shouldIssueCertsFunction · 0.80
maybeProvisionMethod · 0.80
isHTTPRedirectEnabledFunction · 0.80
ShouldUseRoutesFunction · 0.80

Calls 1

GetMethod · 0.95

Tested by 3

TestBoolEqualBoolFunction · 0.64
TestInContainerFunction · 0.64
TestProfileManagementFunction · 0.64