Skip to content

πŸ”₯ πŸ”₯ πŸ”₯ A Free & Self-hostable Airtable Alternative

do not remove thumbnails from v3 attachment response

Fendy Heryantoe495357567fc
diff --git a/packages/nocodb/src/services/v3/data-v3.service.ts b/packages/nocodb/src/services/v3/data-v3.service.ts
index 8d8b993921..d431cdc9fe 100644
--- a/packages/nocodb/src/services/v3/data-v3.service.ts
+++ b/packages/nocodb/src/services/v3/data-v3.service.ts
@@ -14,7 +14,6 @@ import type {
import type { NcContext } from '~/interface/config';
import type { LinkToAnotherRecordColumn } from '~/models';
import type { ReusableParams } from '~/utils';
-import { extractProps } from '~/helpers/extractProps';
import { getCompositePkValue } from '~/helpers/dbHelpers';
import { NcError } from '~/helpers/catchError';
import { Column, Model, Source } from '~/models';
@@ -257,32 +256,6 @@ export class DataV3Service {
});
continue;
}
- } else if (column?.uidt === UITypes.Attachment) {
- if (value) {
- let attachmentVal: any[] = value as any;
- if (!Array.isArray(value) && typeof value === 'string') {
- attachmentVal = JSON.parse(value);
- } else if (!Array.isArray(attachmentVal)) {
- // unknown format, let's not handle it yet
- continue;
- }
-
- attachmentVal = attachmentVal.map((attr) =>
- extractProps(attr, [
- 'id',
- 'url',
- 'path',
- 'title',
- 'mimetype',
- 'size',
- 'icon',
- 'width',
- 'height',
- ]),
- );
- transformedFields[key] = attachmentVal;
- continue;
- }
}
}