Skip to content

Commit

Permalink
fix: ensures non populated relationships still retain IDs
Browse files Browse the repository at this point in the history
  • Loading branch information
jmikrut committed Oct 4, 2021
1 parent d5d7748 commit a201109
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/fields/relationshipPopulationPromise.ts
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ const populate = async ({
idString = idString.toString();
}

let populatedRelationship = null;
let populatedRelationship;

if (depth && currentDepth <= depth) {
populatedRelationship = await payload.operations.collections.findByID({
Expand Down

0 comments on commit a201109

Please sign in to comment.