Skip to content

Change originalLanguage to ISO639-1 standard #279

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

Merged
merged 8 commits into from
Dec 23, 2021
Merged

Conversation

schneidermic0
Copy link
Contributor

No description provided.

@larshp
Copy link
Collaborator

larshp commented Dec 20, 2021

@albertmink
Copy link
Contributor

Closes #34

@schneidermic0 schneidermic0 marked this pull request as ready for review December 20, 2021 15:57
@larshp
Copy link
Collaborator

larshp commented Dec 21, 2021

suggest adding a regular expression in the schema validation, to check its lower case(are numbers allowed?)

@schneidermic0
Copy link
Contributor Author

suggest adding a regular expression in the schema validation, to check its lower case(are numbers allowed?)

I can check whether I can add a pattern (like [a-z]{2}) to the language field. As far as I can see numbers are not allowed

@schneidermic0
Copy link
Contributor Author

I have added the following attributes for language fields

"minLength": 2,
"maxLength": 2,
"pattern": "^[a-z]+$"

@schneidermic0
Copy link
Contributor Author

schneidermic0 commented Dec 21, 2021

BTW - I have also fixed the pattern for numerics. It was [0-9]*, before. For this pattern any string was accepted because the start (^) and the end ($) of the string where missing. * had to be replaced by + so that at least one number is available.
Therefore, it is $[0-9]+$, now.

Copy link
Contributor

@wurzka wurzka left a comment

Choose a reason for hiding this comment

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

In the json.md file, there is an example with a language. There, the minLength and pattern has to be added, too.

@schneidermic0 schneidermic0 requested a review from wurzka December 22, 2021 09:00
Copy link
Contributor

@wurzka wurzka left a comment

Choose a reason for hiding this comment

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

I guess you missed my comment about the json.md file above. Can you add the additional fields in the example json schema there?

@schneidermic0
Copy link
Contributor Author

@wurzka Yes, sorry. I missed your comment.

@schneidermic0 schneidermic0 requested a review from wurzka December 22, 2021 12:36
Copy link
Contributor

@wurzka wurzka left a comment

Choose a reason for hiding this comment

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

Thanks, LGTM :)

@schneidermic0 schneidermic0 merged commit ae1204c into main Dec 23, 2021
@schneidermic0 schneidermic0 deleted the languageHandling branch December 23, 2021 11:10
@schneidermic0 schneidermic0 linked an issue Jan 3, 2022 that may be closed by this pull request
albertmink added a commit to albertmink/CHKO that referenced this pull request Feb 2, 2022
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.

Language, exact field contents?
4 participants