Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

♻️ Rename "metadata" field in SubmitClaims struct to "claims" #580

Closed
ccamel opened this issue Jun 14, 2024 · 1 comment · Fixed by #582
Closed

♻️ Rename "metadata" field in SubmitClaims struct to "claims" #580

ccamel opened this issue Jun 14, 2024 · 1 comment · Fixed by #582
Assignees

Comments

@ccamel
Copy link
Member

ccamel commented Jun 14, 2024

Proposal

The SubmitClaims struct currently has a field named metadata. This name might be misleading as it conveys the idea of a data about data, which is not the quite the case for this action.

    SubmitClaims {
        /// The serialized metadata intended for attachment.
        /// This metadata should adhere to the format specified in the `format` field.
        metadata: Binary,
        /// RDF dataset serialization format for the metadata.
        /// If not provided, the default format is [N-Quads](https://www.w3.org/TR/n-quads/) format.
        format: Option<RdfDatasetFormat>,
    },

Proposal

For clarity and precision, I propose to rename the metadata field to claims as a claim refers to a piece of information about an entity (such as a user, a service) that can be provided by one party and is potentially verifiable.

Impact

  • positive: this change will make the code more readable and self-explanatory
  • negative: this change introduces a breaking-change in the contract
  • neutral: none
@ccamel ccamel changed the title ♻️ Rename "metadata" field in SubmitClaims struct to "claim" ♻️ Rename "metadata" field in SubmitClaims struct to "claims" Jun 14, 2024
@amimart
Copy link
Member

amimart commented Jun 14, 2024

Good catch, I'm 100% ok with that!

@ccamel ccamel self-assigned this Jun 18, 2024
@ccamel ccamel linked a pull request Jun 18, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: ✅ Done
Development

Successfully merging a pull request may close this issue.

2 participants