From 5f0e65fe0c674e40ecb64cedc0d195492cdc08ff Mon Sep 17 00:00:00 2001 From: Ben McCallum Date: Tue, 6 Sep 2022 06:34:30 +1000 Subject: [PATCH] Fixed name of LocalCurrency scalar type (#5368) --- src/HotChocolate/Core/src/Types.Scalars/LocalCurrencyType.cs | 2 +- src/HotChocolate/Core/src/Types.Scalars/ThrowHelper.cs | 4 ++-- .../Core/src/Types.Scalars/WellKnownScalarTypes.cs | 2 +- .../LocalCurrencyTypeTests.Schema_WithScalar_IsMatch.snap | 4 ++-- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/HotChocolate/Core/src/Types.Scalars/LocalCurrencyType.cs b/src/HotChocolate/Core/src/Types.Scalars/LocalCurrencyType.cs index 29be18eb189..b98cd6bf52a 100644 --- a/src/HotChocolate/Core/src/Types.Scalars/LocalCurrencyType.cs +++ b/src/HotChocolate/Core/src/Types.Scalars/LocalCurrencyType.cs @@ -17,7 +17,7 @@ public class LocalCurrencyType : ScalarType /// public LocalCurrencyType() : this( - WellKnownScalarTypes.LocalCurency, + WellKnownScalarTypes.LocalCurrency, description: ScalarResources.LocalCurrencyType_Description) { } diff --git a/src/HotChocolate/Core/src/Types.Scalars/ThrowHelper.cs b/src/HotChocolate/Core/src/Types.Scalars/ThrowHelper.cs index 3d27d8d3374..ec451e29b89 100644 --- a/src/HotChocolate/Core/src/Types.Scalars/ThrowHelper.cs +++ b/src/HotChocolate/Core/src/Types.Scalars/ThrowHelper.cs @@ -206,7 +206,7 @@ public static SerializationException LocalCurrencyType_ParseValue_IsInvalid(ITyp ErrorBuilder.New() .SetMessage(ScalarResources.LocalCurrencyType_IsInvalid_ParseValue) .SetCode(ErrorCodes.Scalars.InvalidRuntimeType) - .SetExtension("actualType", WellKnownScalarTypes.LocalCurency) + .SetExtension("actualType", WellKnownScalarTypes.LocalCurrency) .Build(), type); } @@ -217,7 +217,7 @@ public static SerializationException LocalCurrencyType_ParseLiteral_IsInvalid(IT ErrorBuilder.New() .SetMessage(ScalarResources.LocalDateType_IsInvalid_ParseLiteral) .SetCode(ErrorCodes.Scalars.InvalidSyntaxFormat) - .SetExtension("actualType", WellKnownScalarTypes.LocalCurency) + .SetExtension("actualType", WellKnownScalarTypes.LocalCurrency) .Build(), type); } diff --git a/src/HotChocolate/Core/src/Types.Scalars/WellKnownScalarTypes.cs b/src/HotChocolate/Core/src/Types.Scalars/WellKnownScalarTypes.cs index 81b93247dfc..e2653c8cafd 100644 --- a/src/HotChocolate/Core/src/Types.Scalars/WellKnownScalarTypes.cs +++ b/src/HotChocolate/Core/src/Types.Scalars/WellKnownScalarTypes.cs @@ -11,7 +11,7 @@ internal static class WellKnownScalarTypes public const string Isbn = nameof(Isbn); public const string Latitude = nameof(Latitude); public const string LocalDate = nameof(LocalDate); - public const string LocalCurency = nameof(LocalCurency); + public const string LocalCurrency = nameof(LocalCurrency); public const string LocalTime = nameof(LocalTime); public const string Longitude = nameof(Longitude); public const string MacAddress = nameof(MacAddress); diff --git a/src/HotChocolate/Core/test/Types.Scalars.Tests/__snapshots__/LocalCurrencyTypeTests.Schema_WithScalar_IsMatch.snap b/src/HotChocolate/Core/test/Types.Scalars.Tests/__snapshots__/LocalCurrencyTypeTests.Schema_WithScalar_IsMatch.snap index 2287bf26f5a..1c24a43729f 100644 --- a/src/HotChocolate/Core/test/Types.Scalars.Tests/__snapshots__/LocalCurrencyTypeTests.Schema_WithScalar_IsMatch.snap +++ b/src/HotChocolate/Core/test/Types.Scalars.Tests/__snapshots__/LocalCurrencyTypeTests.Schema_WithScalar_IsMatch.snap @@ -3,7 +3,7 @@ } type Query { - scalar: LocalCurency + scalar: LocalCurrency } "The `@defer` directive may be provided for fragment spreads and inline fragments to inform the executor to delay the execution of the current fragment to indicate deprioritization of the current fragment. A query with `@defer` directive will cause the request to potentially return multiple responses, where non-deferred data is delivered in the initial response and data deferred is delivered in a subsequent response. `@include` and `@skip` take precedence over `@defer`." @@ -13,4 +13,4 @@ directive @defer("If this argument label has a value other than null, it will be directive @stream("If this argument label has a value other than null, it will be passed on to the result of this stream directive. This label is intended to give client applications a way to identify to which fragment a streamed result belongs to." label: String "The initial elements that shall be send down to the consumer." initialCount: Int! = 0 "Streamed when true." if: Boolean) on FIELD "The LocalCurrency scalar type is a currency string." -scalar LocalCurency +scalar LocalCurrency