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

feat: Add know information metadata names for papers #1459

Merged
merged 1 commit into from
Apr 3, 2024
Merged

Conversation

JF-Cozy
Copy link
Contributor

@JF-Cozy JF-Cozy commented Apr 3, 2024

No description provided.

const shouldReturnThisMetadata = Object.keys(metadata).includes(
knownMetadataName
)
const _value = value || get(metadata, knownMetadataName, null)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Juste pour clarifier, ce refacto est bien suite à la décision d'encapsuler les metadata propre à une qualification au sein d'un même object ?
Exemple :

{
  _type: "io.cozy.files",
  name: "Vehicle registration"
  metadata: {
    qualification: { label: "vehicle_registration" }
    vehicle: {
      licenseNumber: "123",
      confidentialNumber: "456"
    }
  }
}

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

c'est ça 👍

@JF-Cozy JF-Cozy requested a review from Merkur39 April 3, 2024 12:29
@JF-Cozy JF-Cozy merged commit 065c17e into master Apr 3, 2024
4 checks passed
@JF-Cozy JF-Cozy deleted the feat/VER-26 branch April 3, 2024 12:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants