diff --git a/apps/nestjs-backend/src/features/plugin/official/official-plugin-init.service.ts b/apps/nestjs-backend/src/features/plugin/official/official-plugin-init.service.ts index f73c71e834..89f11215ba 100644 --- a/apps/nestjs-backend/src/features/plugin/official/official-plugin-init.service.ts +++ b/apps/nestjs-backend/src/features/plugin/official/official-plugin-init.service.ts @@ -66,7 +66,7 @@ export class OfficialPluginInitService implements OnModuleInit { .$queryRawUnsafe< unknown[] >(this.knex('attachments').select('token').where('token', id).forUpdate().toString()); - if (rows.length > 0) { + if (rows.length === 0) { await this.prismaService.txClient().attachments.create({ data: { token: id,