MCPcopy
hub / github.com/kubernetes/client-go / WasCreated

Method WasCreated

rest/request.go:1130–1133  ·  view source on GitHub ↗

WasCreated updates the provided bool pointer to whether the server returned 201 created or a different response.

(wasCreated *bool)

Source from the content-addressed store, hash-verified

1128// WasCreated updates the provided bool pointer to whether the server returned
1129// 201 created or a different response.
1130func (r Result) WasCreated(wasCreated *bool) Result {
1131 *wasCreated = r.statusCode == http.StatusCreated
1132 return r
1133}
1134
1135// Error returns the error executing the request, nil if no error occurred.
1136// If the returned object is of type Status and has Status != StatusSuccess, the

Callers 6

TestDoRequestCreatedFunction · 0.80
TestDoRequestNotCreatedFunction · 0.80
TestBadRequestFunction · 0.80
TestDoRequestNewWayFileFunction · 0.80
TestWasCreatedFunction · 0.80

Calls

no outgoing calls

Tested by 6

TestDoRequestCreatedFunction · 0.64
TestDoRequestNotCreatedFunction · 0.64
TestBadRequestFunction · 0.64
TestDoRequestNewWayFileFunction · 0.64
TestWasCreatedFunction · 0.64