Skip to content

Commit 3690494

Browse files
committed
Draft journal check
1 parent 3915e7b commit 3690494

File tree

2 files changed

+9
-3
lines changed

2 files changed

+9
-3
lines changed

CHANGELOG.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,11 @@ All notable changes to this project will be documented in this file.
55
The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
66
and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).
77

8-
## Version 0.3.4 - 2026-02-xx
8+
## Version 0.3.4 - 2026-01-20
99

1010
### Fixed
1111

12-
- tbd
12+
- Fix journal migration check for draft entities
1313

1414
## Version 0.3.3 - 2026-01-07
1515

src/migration-check/MigrationCheck.js

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -559,7 +559,10 @@ function journalModeCheck(csnBuild, csnProd, whitelist, options) {
559559
}
560560
visitPersistenceEntities(
561561
csnBuild,
562-
(definitionBuild) => {
562+
(definitionBuild, { draft } = {}) => {
563+
if (draft) {
564+
return;
565+
}
563566
const definitionProd = csnProd.definitions[definitionBuild.name];
564567
if (definitionProd) {
565568
if (definitionBuild["@cds.persistence.journal"] && !definitionProd["@cds.persistence.journal"]) {
@@ -616,6 +619,9 @@ function visitPersistenceEntities(csn, onEntity, filter) {
616619
if (partOfService) {
617620
const _compositeEntities = compositeEntities(csn.definitions, name);
618621
_compositeEntities.forEach((name) => {
622+
if (filter && !filter.includes(name)) {
623+
return;
624+
}
619625
const definition = csn.definitions[name];
620626
definition.name = name;
621627
onEntity(definition, { draft: true });

0 commit comments

Comments
 (0)