get the user defined system key value for updating (#2134)

* get the user defined system key value for updating

* Added the systemkey check for non-defined system key
This commit is contained in:
sunghyunkang1111 2025-05-08 09:14:09 -05:00 committed by GitHub
parent 2dbec019af
commit 985c744198
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -124,7 +124,7 @@ export const extractPartitionKeyValues = (
documentContent: any, documentContent: any,
partitionKeyDefinition: PartitionKeyDefinition, partitionKeyDefinition: PartitionKeyDefinition,
): PartitionKey[] => { ): PartitionKey[] => {
if (!partitionKeyDefinition.paths || partitionKeyDefinition.paths.length === 0 || partitionKeyDefinition.systemKey) { if (!partitionKeyDefinition.paths || partitionKeyDefinition.paths.length === 0) {
return undefined; return undefined;
} }
@ -136,7 +136,7 @@ export const extractPartitionKeyValues = (
if (value !== undefined) { if (value !== undefined) {
partitionKeyValues.push(value); partitionKeyValues.push(value);
} else { } else if (!partitionKeyDefinition.systemKey) {
partitionKeyValues.push({}); partitionKeyValues.push({});
} }
}); });