From 1a27ad1079166123918a016c2ce93710c55bfa88 Mon Sep 17 00:00:00 2001 From: Joris Eijmberts <25585505+ThePartyPinguin@users.noreply.github.com> Date: Mon, 8 Jul 2024 14:50:21 +0000 Subject: [PATCH] Fixes incorrect exception message and property name reference --- .../src/FeedRange/VersionedAndRidCheckedCompositeToken.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Microsoft.Azure.Cosmos/src/FeedRange/VersionedAndRidCheckedCompositeToken.cs b/Microsoft.Azure.Cosmos/src/FeedRange/VersionedAndRidCheckedCompositeToken.cs index ebbeb43355..66e6472348 100644 --- a/Microsoft.Azure.Cosmos/src/FeedRange/VersionedAndRidCheckedCompositeToken.cs +++ b/Microsoft.Azure.Cosmos/src/FeedRange/VersionedAndRidCheckedCompositeToken.cs @@ -60,13 +60,13 @@ public static TryCatch MonadicCreateFromCo if (!cosmosObject.TryGetValue(PropertyNames.Continuation, out CosmosElement continuationValue)) { return TryCatch.FromException( - new FormatException($"expected number {nameof(PropertyNames.Continuation)} property for {nameof(VersionedAndRidCheckedCompositeToken)}: {cosmosElement}.")); + new FormatException($"expected object {nameof(PropertyNames.Continuation)} property for {nameof(VersionedAndRidCheckedCompositeToken)}: {cosmosElement}.")); } if (!cosmosObject.TryGetValue(PropertyNames.Rid, out CosmosString ridValue)) { return TryCatch.FromException( - new FormatException($"expected number {nameof(PropertyNames.Version)} property for {nameof(VersionedAndRidCheckedCompositeToken)}: {cosmosElement}.")); + new FormatException($"expected string {nameof(PropertyNames.Rid)} property for {nameof(VersionedAndRidCheckedCompositeToken)}: {cosmosElement}.")); } VersionedAndRidCheckedCompositeToken token = new VersionedAndRidCheckedCompositeToken(