Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,14 +1,12 @@

#nullable enable

#pragma warning disable CS0618 // Type or member is obsolete
#pragma warning disable CS3016 // Arrays as attribute arguments is not CLS-compliant

namespace WaveSpeedAI
{
/// <summary>
///
/// </summary>
#pragma warning disable CS3016 // Converter type array in this attribute is not CLS-compliant.
[global::System.Text.Json.Serialization.JsonSourceGenerationOptions(
DefaultIgnoreCondition = global::System.Text.Json.Serialization.JsonIgnoreCondition.WhenWritingNull,
Converters = new global::System.Type[]
Expand Down Expand Up @@ -45,6 +43,7 @@ namespace WaveSpeedAI

typeof(global::WaveSpeedAI.JsonConverters.UnixTimestampJsonConverter),
})]
#pragma warning restore CS3016
[global::System.Text.Json.Serialization.JsonSerializable(typeof(global::WaveSpeedAI.JsonSerializerContextTypes))]
[global::System.Text.Json.Serialization.JsonSerializable(typeof(global::System.Collections.Generic.List<object>), TypeInfoPropertyName = "SystemCollectionsGeneric_ObjectList")]
[global::System.Text.Json.Serialization.JsonSerializable(typeof(global::WaveSpeedAI.ApiResponse))]
Expand Down
Original file line number Diff line number Diff line change
@@ -1,19 +1,14 @@

#nullable enable

#pragma warning disable CS0618 // Type or member is obsolete
#pragma warning disable CS3016 // Arrays as attribute arguments is not CLS-compliant

namespace WaveSpeedAI
{
/// <summary>
///
/// </summary>
[global::System.Text.Json.Serialization.JsonSourceGenerationOptions(
DefaultIgnoreCondition = global::System.Text.Json.Serialization.JsonIgnoreCondition.WhenWritingNull,
Converters = new global::System.Type[]
{
})]
DefaultIgnoreCondition = global::System.Text.Json.Serialization.JsonIgnoreCondition.WhenWritingNull
)]
[global::System.Text.Json.Serialization.JsonSerializable(typeof(global::System.Collections.Generic.Dictionary<string, string>))]
[global::System.Text.Json.Serialization.JsonSerializable(typeof(global::System.Collections.Generic.Dictionary<string, object>))]
[global::System.Text.Json.Serialization.JsonSerializable(typeof(global::System.Collections.Generic.List<object>), TypeInfoPropertyName = "SystemCollectionsGeneric_ObjectList")]
Expand Down
15 changes: 8 additions & 7 deletions src/libs/WaveSpeedAI/Generated/WaveSpeedAI.OptionsSupport.g.cs
Original file line number Diff line number Diff line change
Expand Up @@ -241,7 +241,8 @@ public sealed class AutoSDKAuthorizationProviderHook : global::WaveSpeedAI.AutoS
{
context = context ?? throw new global::System.ArgumentNullException(nameof(context));

if (context.Request == null)
var request = context.Request;
if (request == null)
{
return;
}
Expand All @@ -251,10 +252,10 @@ public sealed class AutoSDKAuthorizationProviderHook : global::WaveSpeedAI.AutoS
{
for (var index = 0; index < perRequest.Count; index++)
{
ApplyAuthorization(context.Request, perRequest[index]);
ApplyAuthorization(request, perRequest[index]);
}

global::WaveSpeedAI.AutoSDKHttpRequestOptions.StampAuthorizationOverride(context.Request);
global::WaveSpeedAI.AutoSDKHttpRequestOptions.StampAuthorizationOverride(request);
return;
}

Expand All @@ -272,10 +273,10 @@ public sealed class AutoSDKAuthorizationProviderHook : global::WaveSpeedAI.AutoS

for (var index = 0; index < resolved.Count; index++)
{
ApplyAuthorization(context.Request, resolved[index]);
ApplyAuthorization(request, resolved[index]);
}

global::WaveSpeedAI.AutoSDKHttpRequestOptions.StampAuthorizationOverride(context.Request);
global::WaveSpeedAI.AutoSDKHttpRequestOptions.StampAuthorizationOverride(request);
}

private static void ApplyAuthorization(
Expand Down Expand Up @@ -486,7 +487,7 @@ public sealed class AutoSDKHookContext
/// <summary>
/// The outgoing HTTP request for the current attempt.
/// </summary>
public global::System.Net.Http.HttpRequestMessage Request { get; set; } = null!;
public global::System.Net.Http.HttpRequestMessage? Request { get; set; }

/// <summary>
/// The HTTP response when one was received.
Expand All @@ -501,7 +502,7 @@ public sealed class AutoSDKHookContext
/// <summary>
/// The client-wide runtime options.
/// </summary>
public global::WaveSpeedAI.AutoSDKClientOptions ClientOptions { get; set; } = null!;
public global::WaveSpeedAI.AutoSDKClientOptions? ClientOptions { get; set; }

/// <summary>
/// The per-request runtime options.
Expand Down
Loading