MCPcopy Index your code
hub / github.com/callstack/agent-device / isTrustedInstallSourceUrl

Function isTrustedInstallSourceUrl

src/platforms/install-source.ts:214–223  ·  view source on GitHub ↗
(sourceUrl: string | URL)

Source from the content-addressed store, hash-verified

212}
213
214export function isTrustedInstallSourceUrl(sourceUrl: string | URL): boolean {
215 const parsed = sourceUrl instanceof URL ? sourceUrl : new URL(sourceUrl);
216 const hostname = parsed.hostname.toLowerCase();
217 if (!hostname) return false;
218 const pathname = parsed.pathname;
219 return (
220 isTrustedGithubActionsArtifactUrl(hostname, pathname) ||
221 isTrustedEasArtifactUrl(hostname, pathname)
222 );
223}
224
225function isTrustedGithubActionsArtifactUrl(hostname: string, pathname: string): boolean {
226 if (hostname === 'api.github.com') {

Calls 2

isTrustedEasArtifactUrlFunction · 0.85

Tested by

no test coverage detected