Skip to content

Allow object to be nil if they're optional #1831

Open
@stephybun

Description

@stephybun

In batch we have a scenario where we test removal of the autoStorage properties set on the batch account.

Previously this was done by setting the sub-property storageAccountID to nil using the azure-sdk-for-go which, due to a bug in the SDK generator, allows a pointer to be the sent even though the field itself is marked as Required in the swagger.

As per the service team's suggestion the proper way to remove this setting is to set the whole autoStorage object to null which isn't possible in Pandora currently since Optional objects are given the omitempty tag.

The proposed solution would be to remove the omitempty tag for singular objects.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions