(source string)
| 67 | } |
| 68 | |
| 69 | func parseTaskResultFunctionBody(source string) string { |
| 70 | marker := strings.Index(source, "function parseTaskResult") |
| 71 | if marker < 0 { |
| 72 | return "" |
| 73 | } |
| 74 | brace := strings.Index(source[marker:], "{") |
| 75 | if brace < 0 { |
| 76 | return "" |
| 77 | } |
| 78 | start := marker + brace |
| 79 | depth := 0 |
| 80 | for i := start; i < len(source); i++ { |
| 81 | switch source[i] { |
| 82 | case '{': |
| 83 | depth++ |
| 84 | case '}': |
| 85 | depth-- |
| 86 | if depth == 0 { |
| 87 | return source[start : i+1] |
| 88 | } |
| 89 | } |
| 90 | } |
| 91 | return "" |
| 92 | } |
no outgoing calls
no test coverage detected