MCPcopy Index your code
hub / github.com/massCodeIO/massCode / getGistFiles

Function getGistFiles

src/main/import/snippets/githubGists.ts:66–79  ·  view source on GitHub ↗
(gist: GitHubGistResponse)

Source from the content-addressed store, hash-verified

64}
65
66function getGistFiles(gist: GitHubGistResponse): GitHubGistFile[] {
67 if (
68 !gist.files
69 || typeof gist.files !== 'object'
70 || Array.isArray(gist.files)
71 ) {
72 return []
73 }
74
75 return Object.values(gist.files).filter(
76 (file): file is GitHubGistFile =>
77 !!file && typeof file === 'object' && !Array.isArray(file),
78 )
79}
80
81const GIST_FETCH_TIMEOUT_MS = 15_000
82

Callers 1

parseGitHubGistResponseFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected