add jsonv-ts as dependency for type inference, fix media api types (#227)

* add jsonv-ts as dependency for type inference, fix media api types

* add jsonv-ts as dependency for type inference, fix media api types

* add jsonv-ts as dependency for type inference, fix media api types
This commit is contained in:
dswbx
2025-08-06 08:21:17 +02:00
committed by GitHub
parent aa0e6f90d9
commit ad0d2e6ff8
5 changed files with 13 additions and 13 deletions

View File

@@ -68,7 +68,7 @@ export class MediaApi extends ModuleApi<MediaApiOptions> {
}
protected uploadFile(
body: File | Blob | ReadableStream,
body: File | Blob | ReadableStream | Buffer<ArrayBufferLike>,
opts?: {
filename?: string;
path?: TInput;
@@ -110,7 +110,7 @@ export class MediaApi extends ModuleApi<MediaApiOptions> {
}
async upload(
item: Request | Response | string | File | Blob | ReadableStream,
item: Request | Response | string | File | Blob | ReadableStream | Buffer<ArrayBufferLike>,
opts: {
filename?: string;
_init?: Omit<RequestInit, "body">;
@@ -148,7 +148,7 @@ export class MediaApi extends ModuleApi<MediaApiOptions> {
entity: string,
id: PrimaryFieldType,
field: string,
item: Request | Response | string | File | ReadableStream,
item: Request | Response | string | File | ReadableStream | Buffer<ArrayBufferLike>,
opts?: {
_init?: Omit<RequestInit, "body">;
fetcher?: typeof fetch;