Skip to content

Allow unset data in DescriptorDataBuilder #66

@ohager

Description

@ohager

Is your feature request related to a problem? Please describe.
In a current scenario I need to remove certain elements from the SRC44 Databuilder.

        const oldData = DescriptorData.parse(ledgerAlias.aliasURI, false);
        builder = DescriptorDataBuilder.createWith(oldData);
        // @ts-ignore
        builder.setAlias(undefined)

I needed to ignore Typescript check, when removing alias reference.

Describe the solution you'd like
It could be possible to allow undefined values, but for better readability I recommend to introduce something like unset

        const oldData = DescriptorData.parse(ledgerAlias.aliasURI, false);
        builder = DescriptorDataBuilder.createWith(oldData);
        builder.unsetAlias()

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requeststandardsThe standards module

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions