MCPcopy Create free account
hub / github.com/buggregator/server / toLineNumber

Function toLineNumber

modules/sentry/source_context.go:226–240  ·  view source on GitHub ↗
(v any)

Source from the content-addressed store, hash-verified

224}
225
226func toLineNumber(v any) (int, bool) {
227 switch n := v.(type) {
228 case float64:
229 return int(n), true
230 case json.Number:
231 i, err := n.Int64()
232 if err != nil {
233 return 0, false
234 }
235 return int(i), true
236 case int:
237 return n, true
238 }
239 return 0, false
240}

Callers 1

enrichFrameFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected