File tree Expand file tree Collapse file tree 3 files changed +8
-3
lines changed
packages/service-utils/src/cf-worker Expand file tree Collapse file tree 3 files changed +8
-3
lines changed Original file line number Diff line number Diff line change 1+ ---
2+ " @thirdweb-dev/service-utils " : patch
3+ ---
4+
5+ [ service-utils] remove unneeded cloudflare worker types
Original file line number Diff line number Diff line change 11import type {
22 ExecutionContext ,
33 KVNamespace ,
4+ Request ,
45 Response ,
56} from "@cloudflare/workers-types" ;
6- import type { Request } from "@cloudflare/workers-types" ;
77import type { CoreServiceConfig , TeamAndProjectResponse } from "../core/api.js" ;
88import { authorize } from "../core/authorize/index.js" ;
99import type {
Original file line number Diff line number Diff line change 1- import { Headers , type Request , fetch } from "@cloudflare/workers-types" ;
1+ import type { Request } from "@cloudflare/workers-types" ;
22import type { CoreAuthInput } from "../core/types.js" ;
33import type {
44 ClientUsageV2Event ,
@@ -34,7 +34,7 @@ export async function sendUsageV2Events<T extends UsageV2Options>(
3434 // Forward headers from the origin request.
3535 // Determine endpoint and auth header based on provided credentials.
3636 let url : string ;
37- const headers = new Headers ( authInput . req . headers ) ;
37+ const headers = new Headers ( Object . fromEntries ( authInput . req . headers ) ) ;
3838 headers . set ( "Content-Type" , "application/json" ) ;
3939 if ( serviceKey ) {
4040 // If a service key is provided, call the non-public usage endpoint.
You can’t perform that action at this time.
0 commit comments