(...args: Array<any>)
| 10 | const serverFnMeta: ClientFnMeta = { id: functionId } |
| 11 | |
| 12 | const fn = async (...args: Array<any>): Promise<any> => { |
| 13 | // If an importer is provided, use it directly (server-to-server call within the SSR environment) |
| 14 | // Otherwise, fall back to manifest lookup (client-to-server call, server functions that are only referenced on the server or if the provider environment is not SSR) |
| 15 | const serverFn = importer |
| 16 | ? await importer() |
| 17 | : await getServerFnById(functionId) |
| 18 | return serverFn(...args) |
| 19 | } |
| 20 | |
| 21 | return Object.assign(fn, { |
| 22 | url, |
no test coverage detected