MCPcopy Create free account
hub / github.com/CapSoftware/Cap / assertDriveResponse

Function assertDriveResponse

packages/web-backend/src/Storage/GoogleDrive.ts:124–128  ·  view source on GitHub ↗
(response: Response)

Source from the content-addressed store, hash-verified

122};
123
124const assertDriveResponse = async (response: Response) => {
125 if (response.ok || response.status === 308) return;
126 const text = await response.text().catch(() => "");
127 throw new Error(`Google Drive request failed: ${response.status} ${text}`);
128};
129
130const escapeDriveQueryValue = (value: string) =>
131 value.replace(/\\/g, "\\\\").replace(/'/g, "\\'");

Callers 3

exchangeGoogleDriveCodeFunction · 0.85
driveFetchFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected