MCPcopy
hub / github.com/github/github-mcp-server / isAcceptedError

Function isAcceptedError

pkg/github/params.go:38–41  ·  view source on GitHub ↗

isAcceptedError checks if the error is an accepted error.

(err error)

Source from the content-addressed store, hash-verified

36
37// isAcceptedError checks if the error is an accepted error.
38func isAcceptedError(err error) bool {
39 var acceptedError *github.AcceptedError
40 return errors.As(err, &acceptedError)
41}
42
43// toInt converts a value to int, handling both float64 and string representations.
44// Some MCP clients send numeric values as strings. It rejects NaN, ±Inf,

Callers 3

ForkRepositoryFunction · 0.85
Test_IsAcceptedErrorFunction · 0.85
UpdatePullRequestBranchFunction · 0.85

Calls 1

AsMethod · 0.80

Tested by 1

Test_IsAcceptedErrorFunction · 0.68