0.10.0 has one breaking change in the library. Nothing changes in the command line or in the PowerShell module. The other
changes in this release are in the release notes.
CompanyStatus.Enabled and all 17 WebhookOptions flags changed from bool to bool?. DK Plus can return null for these
values, and earlier versions silently turned it into false. The properties now keep the null.
You must recompile against 0.10.0, and code that reads these members must handle null.
CompanyStatus? status = await client.Company.GetStatusAsync(cancellationToken);
// Before: bool enabled = status.Enabled;
bool enabled = status?.Enabled == true; // null counts as "not enabled"
// or keep the distinction:
if (status?.Enabled is null)
{
// DK Plus did not report a value
}
The same applies to every WebhookOptions flag (Enabled and the 16 event flags such as Customer and SalesOrder):
WebhookSubscription? webhook = await client.Webhook.GetAsync(webhookId, cancellationToken);
bool deliverCustomerEvents = webhook?.Options?.Customer == true;
bool use with == true, ?? false, or an explicit null check, depending on what null should meantrue or false to a flag still compiles.Pre-1.0 releases do not promise source or binary compatibility of the public API. This does not remove the netstandard2.0
(.NET Framework 4.8) runtime target, which 0.10.0 adds for the library packages.
Back to Upgrading.