File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -54,6 +54,8 @@ export const STORE_FILE_IMAGE_TYPES = [
5454 * in a high-throughput scenario you may want to schedule a job which calls
5555 * {@link fileTransformInPlace} instead of passing this option directly.
5656 *
57+ * @template {import("./generated/common/types.d.ts").StoreFileMetaInput} T
58+ *
5759 * @param {import("postgres").Sql } sql
5860 * @param {import("@aws-sdk/client-s3").S3Client } s3Client
5961 * @param {{
@@ -62,8 +64,10 @@ export const STORE_FILE_IMAGE_TYPES = [
6264 * schedulePlaceholderImageJob?: boolean,
6365 * fileTransformInPlaceOptions?: FileTransformInPlaceOptions,
6466 * }} options
65- * @param {Partial<import("./generated/common/types.d.ts").StoreFile> & Pick<import("./generated/common/types.d.ts").StoreFile,
66- * "name">} props
67+ * @param {Omit<Partial<import("./generated/common/types.d.ts").StoreFile>, "name"|"meta"> & {
68+ * name: string;
69+ * meta: T;
70+ * }} props
6771 * @param {import("stream").Readable|string|Buffer } source
6872 * @returns {Promise<import("./generated/common/types.d.ts").StoreFile> }
6973 */
@@ -103,6 +107,7 @@ export async function fileCreateOrUpdate(
103107 }
104108
105109 props . bucketName = options . bucketName ;
110+ // @ts -expect-error this is fine!
106111 props . meta = props . meta ?? { } ;
107112
108113 if ( typeof source === "string" ) {
You can’t perform that action at this time.
0 commit comments