Skip to content

Extend Reference functionality #272

@DiegoFaFe

Description

@DiegoFaFe

Motivation

Using the sdk I've noticed some code that we end up repeating pretty often around References, like having to create a new reference to request a language variant of a content item that I already have, or checking agaisnt Guid.Empty when I want to filter if the items are in the default language/workflow...

Proposed solution

  • Add a static Default method to Reference class (will return a Reference instance with Guid.Empty id and default codename)
  • Implement IEquatable to Reference class
  • Add Implicit conversor from sdk models (ContentItemModel, LanguageVariantModel...) to Reference

Additional context

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