From 9b8c11c66dc1c29c6b497e9d118c5240ff055c8a Mon Sep 17 00:00:00 2001 From: Pranav C Date: Sat, 28 Jan 2023 20:50:37 +0530 Subject: [PATCH] fix: get project using `ncMeta.metaGet2` method Signed-off-by: Pranav C --- .../nocodb/src/lib/version-upgrader/ncAttachmentUpgrader.ts | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/packages/nocodb/src/lib/version-upgrader/ncAttachmentUpgrader.ts b/packages/nocodb/src/lib/version-upgrader/ncAttachmentUpgrader.ts index 84508def4e..6e467ffda0 100644 --- a/packages/nocodb/src/lib/version-upgrader/ncAttachmentUpgrader.ts +++ b/packages/nocodb/src/lib/version-upgrader/ncAttachmentUpgrader.ts @@ -47,7 +47,11 @@ export default async function ({ ncMeta }: NcUpgraderCtx) { for (const _base of bases) { const base = new Base(_base); - const isProjectDeleted = (await base.getProject(ncMeta)).deleted; + const isProjectDeleted = ( + await ncMeta.metaGet2(null, null, MetaTable.PROJECT, { + id: base.project_id, + }) + ).deleted; const knex: Knex = base.is_meta ? ncMeta.knexConnection