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

Default "max_items" value set to null #107

Closed
AlexHodson opened this issue May 16, 2024 · 2 comments · Fixed by #108
Closed

Default "max_items" value set to null #107

AlexHodson opened this issue May 16, 2024 · 2 comments · Fixed by #108
Labels

Comments

@AlexHodson
Copy link
Contributor

Just tried to install on a new machine and when I first run the "better-commits" command. The following response was given:

Found global config

■ Invalid Configuration: commit_type.max_items
│ Invalid type: Expected number but received null

I've had a look into the base global configuration file and for both commit_type.max_items & commit_scope.max_items are both set to null by default. Tried inputting the default configuration provided in the README, but the compains about "Infinity". Only way I can resolve this is to hardcode the max_items property to a specific number.

Everduin94 added a commit that referenced this issue May 16, 2024
Replaced Infinity default with 20, added min value validator.

Closes: #107
Everduin94 added a commit that referenced this issue May 16, 2024
Replaced Infinity default with 20, added min value validator.

Closes: #107
github-actions bot pushed a commit that referenced this issue May 16, 2024
## [1.15.7](v1.15.6...v1.15.7) (2024-05-16)

### Bug Fixes

* **main:** [#107](#107) max items bug ([#108](#108)) ([6925cfe](6925cfe))
Copy link

🎉 This issue has been resolved in version 1.15.7 🎉

The release is available on:

Your semantic-release bot 📦🚀

@Everduin94
Copy link
Owner

@AlexHodson - Thanks for catching / reporting this!

I didn't test defaults on a PR someone submitted. I goofed 🤦. Infinity on number never works with Valibot and the prop didn't have a min number validator either.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants