Skip to content

Commit a7f3943

Browse files
committed
Update copyright notice
1 parent 75609cd commit a7f3943

File tree

4 files changed

+8
-8
lines changed

4 files changed

+8
-8
lines changed

LICENSE.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
2121
SOFTWARE.
2222

2323
Portions Copyright (c) 2025 Svix (https://www.svix.com) used under MIT licence,
24-
see https://github.com/standard-webhooks/standard-webhooks/blob/main/libraries/LICENSE.
24+
see https://github.com/svix/svix-webhooks/blob/main/LICENSE
2525

2626
Portions Copyright (c) Stripe Inc used under Apache License v2.0, see
2727
https://github.com/stripe/stripe-dotnet/blob/master/LICENSE

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ leveraging the retry capabilites of the [Polly](https://github.com/App-vNext/Pol
7979
This project leverages the work of the **Standard Webhooks** project, published on Github in the [standard-webhooks](https://github.com/standard-webhooks/standard-webhooks) repository.
8080
Specifically it builds upon the [C# reference implementation](https://github.com/standard-webhooks/standard-webhooks/tree/main/libraries/csharp).
8181

82-
Signature verification is based on the [svix-webhooks implementation](https://github.com/svix/svix-webhooks).
82+
Signature verification is based on the [svix-webhooks implementation](https://github.com/svix/svix-webhooks), used under MIT.
8383

8484
## License
8585
This project is licensed under the MIT License.

src/StandardWebhooks/StandardWebhook.cs

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
1-
// Copyright (c) 2024, Codefactors Ltd.
1+
// Copyright (c) 2024, Codefactors Ltd.
22
//
33
// Codefactors Ltd licenses this file to you under the following license(s):
44
//
55
// * The MIT License, see https://opensource.org/license/mit/
66

77
// Portions Copyright (c) 2025 Svix (https://www.svix.com) used under MIT licence,
8-
// see https://github.com/standard-webhooks/standard-webhooks/blob/main/libraries/LICENSE.
8+
// see https://github.com/svix/svix-webhooks/blob/main/LICENSE.
99

1010
using System.Buffers;
1111
using System.Buffers.Text;
@@ -182,8 +182,6 @@ public string Sign(
182182
/// the payload is serialized.</param>
183183
/// <returns>An <see cref="HttpContent"/> initialised with the JSON serialized payload and necessary
184184
/// headers set.</returns>
185-
[RequiresUnreferencedCode("This code path does not support NativeAOT. Use the JsonSerializationContext overload for NativeAOT Scenarios.")]
186-
[RequiresDynamicCode("This code path does not support NativeAOT. Use the JsonSerializationContext overload for NativeAOT Scenarios.")]
187185
public HttpContent MakeHttpContent<T>(T body, string msgId, DateTimeOffset timestamp, JsonSerializerOptions? jsonOptions = null)
188186
{
189187
var content = WebhookContent<T>.Create(body, jsonOptions);

src/StandardWebhooks/WebhookContent.cs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,11 +33,13 @@ private WebhookContent(byte[] content)
3333
/// <param name="jsonOptions">The JSON serialization options to be used to serialize the content. Optional,
3434
/// defaults to <see cref="JsonSerializerDefaults.Web"/> with WriteIndented set to false.</param>
3535
/// <returns>New instance of a <see cref="WebhookContent{T}"/>.</returns>
36-
[RequiresDynamicCode("This code path does not support NativeAOT. Use the JsonSerializationContext overload for NativeAOT Scenarios.")]
37-
[RequiresUnreferencedCode("This code path does not support NativeAOT. Use the JsonSerializationContext overload for NativeAOT Scenarios.")]
3836
public static WebhookContent<T> Create(T content, JsonSerializerOptions? jsonOptions = null)
3937
{
38+
#pragma warning disable IL3050 This overload can still be used in NativeAOT as long as the serializer context has been provided to the options object.
39+
#pragma warning disable IL2026
4040
var utf8bytes = JsonSerializer.SerializeToUtf8Bytes(content, jsonOptions ?? WebhookContentDefaults.JsonSerializerOptions);
41+
#pragma warning restore IL2026
42+
#pragma warning restore IL3050
4143

4244
return new WebhookContent<T>(utf8bytes);
4345
}

0 commit comments

Comments
 (0)