Skip to content

Commit

Permalink
- Fix misleading parameter types for .NET examples
Browse files Browse the repository at this point in the history
  • Loading branch information
nwithan8 committed Apr 23, 2024
1 parent ad8b28b commit 3a034bc
Show file tree
Hide file tree
Showing 6 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion official/docs/csharp/current/batches/add-shipments.cs
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ public static async Task Main()

Parameters.Batch.AddShipments parameters = new()
{
Shipments = new List<Shipment> { shipment },
Shipments = new List<IShipmentParameter> { shipment },
};

batch = await client.Batch.AddShipments(batch.Id, parameters);
Expand Down
2 changes: 1 addition & 1 deletion official/docs/csharp/current/batches/create.cs
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ public static async Task Main()

Parameters.Batch.Create parameters = new()
{
Shipments = new List<Shipment>()
Shipments = new List<IShipmentParameter>()
{
shipment
}
Expand Down
2 changes: 1 addition & 1 deletion official/docs/csharp/current/batches/remove-shipments.cs
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ public static async Task Main()

Parameters.Batch.RemoveShipments parameters = new()
{
Shipments = new List<Shipment> { shipment },
Shipments = new List<IShipmentParameter> { shipment },
};

batch = await client.Batch.RemoveShipments(batch.Id, parameters);
Expand Down
2 changes: 1 addition & 1 deletion official/docs/csharp/current/orders/create.cs
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ public static async Task Main()
Country = "US",
Zip = "94104"
},
Shipments = new List<Shipment>() { shipment }
Shipments = new List<IShipmentParameter>() { shipment }
};

Order order = await client.Order.Create(parameters);
Expand Down
6 changes: 3 additions & 3 deletions official/docs/csharp/current/orders/one-call-buy.cs
Original file line number Diff line number Diff line change
Expand Up @@ -36,16 +36,16 @@ public static async Task Main()
Country = "US",
Zip = "94104"
},
Shipments = new List<Parameters.Shipment.Create>
Shipments = new List<IShipmentParameter>
{
new()
new Parameters.Shipments.Create()
{
Parcel = new Parameters.Parcel.Create
{
Weight = 10.2
}
},
new()
new Parameters.Shipments.Create()
{
Parcel = new Parameters.Parcel.Create
{
Expand Down
2 changes: 1 addition & 1 deletion official/docs/csharp/current/scan-form/create.cs
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ public static async Task Main()

Parameters.ScanForm.Create parameters = new()
{
Shipments = new List<Shipment>
Shipments = new List<IShipmentParameter>
{
shipment
}
Expand Down

0 comments on commit 3a034bc

Please sign in to comment.