Skip to content

Commit

Permalink
Update constraints
Browse files Browse the repository at this point in the history
  • Loading branch information
Mrtenz committed Sep 13, 2024
1 parent e6af643 commit 25ef1b7
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion yarn.config.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -383,7 +383,10 @@ function expectWorkspaceField(workspace, fieldName, expectedValue = undefined) {
workspace.set(fieldName, expectedValue);
} else if (expectedValue === null) {
workspace.unset(fieldName);
} else if (fieldValue === undefined || fieldValue === null) {
} else if (
expectedValue === undefined &&
(fieldValue === undefined || fieldValue === null)
) {
workspace.error(`Missing required field "${fieldName}".`);
}
}
Expand Down

0 comments on commit 25ef1b7

Please sign in to comment.