(value any)
| 35 | } |
| 36 | |
| 37 | func containsDeprecatedGitHubAppID(value any) bool { |
| 38 | switch v := value.(type) { |
| 39 | case map[string]any: |
| 40 | for key, child := range v { |
| 41 | if key == "github-app" { |
| 42 | if appMap, ok := child.(map[string]any); ok { |
| 43 | if _, hasAppID := appMap["app-id"]; hasAppID { |
| 44 | return true |
| 45 | } |
| 46 | } |
| 47 | } |
| 48 | if containsDeprecatedGitHubAppID(child) { |
| 49 | return true |
| 50 | } |
| 51 | } |
| 52 | case []any: |
| 53 | return slices.ContainsFunc(v, containsDeprecatedGitHubAppID) |
| 54 | } |
| 55 | return false |
| 56 | } |
| 57 | |
| 58 | func renameGitHubAppIDToClientID(lines []string) ([]string, bool) { |
| 59 | result := make([]string, 0, len(lines)) |
no outgoing calls
no test coverage detected