From 2c03649c6277fd70c321e093c8cddbd8ac3bdbcd Mon Sep 17 00:00:00 2001 From: Nicolas Dupont Date: Mon, 17 Nov 2025 11:36:29 +0100 Subject: [PATCH 1/2] Fix saving records with MongoDB storage --- src/archivist/recorder/repositories/mongo/index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/archivist/recorder/repositories/mongo/index.js b/src/archivist/recorder/repositories/mongo/index.js index b3a23b801..2a4abb18c 100644 --- a/src/archivist/recorder/repositories/mongo/index.js +++ b/src/archivist/recorder/repositories/mongo/index.js @@ -135,7 +135,7 @@ export default class MongoRepository extends RepositoryInterface { async #toPersistence(record) { if (record.content === undefined || record.content === null) { - await this.repository.loadRecordContent(record); + await this.loadRecordContent(record); } return DataMapper.toPersistence(record); From e4b0f405539029c0887e3b570ec1c83e62c96064 Mon Sep 17 00:00:00 2001 From: Nicolas Dupont Date: Mon, 17 Nov 2025 11:36:34 +0100 Subject: [PATCH 2/2] Add changelog entry --- CHANGELOG.md | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index ffb1b7f93..db38ba3b2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,14 @@ All changes that impact users of this module are documented in this file, in the [Common Changelog](https://common-changelog.org) format with some additional specifications defined in the CONTRIBUTING file. This codebase adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## Unreleased [patch] + +> Development of this release was supported by the [French Ministry for Foreign Affairs](https://www.diplomatie.gouv.fr/fr/politique-etrangere-de-la-france/diplomatie-numerique/) through its ministerial [State Startups incubator](https://beta.gouv.fr/startups/open-terms-archive.html) under the aegis of the Ambassador for Digital Affairs. + +### Fixed + +- Fix saving records whose content is not yet loaded when using MongoDB storage. + ## 9.2.1 - 2025-11-19 _Full changeset and discussions: [#1206](https://github.com/OpenTermsArchive/engine/pull/1206)._