diff options
author | TimberBro <mr.demix@yandex.ru> | 2023-08-20 18:06:42 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-08-20 15:06:42 +0000 |
commit | 84d05516dc430a7fbaf0572e976771e6785e208a (patch) | |
tree | 125bab33029390571683f4287c5a5072f89a1f01 /CHANGELOG.md | |
parent | ead52dd96ca86617ecddd819f23322d71c63d01f (diff) | |
download | gitea-84d05516dc430a7fbaf0572e976771e6785e208a.tar.gz gitea-84d05516dc430a7fbaf0572e976771e6785e208a.zip |
Fix NPM packages name validation (#26595)
- Added new tests to cover corner cases
- Replace existing regex with new one
Closes #26551
---
As @silverwind suggested, I started from
[validate-npm-package-name](https://github.com/npm/validate-npm-package-name),
but found this solution too complicated.
Then I tried to fix existing regex myself, but thought, that exclude all
restricted symbols is harder, than set only allowed symbols.
Then I search a bit more and found
[package-name-regex](https://github.com/dword-design/package-name-regex)
and regex from it works for all new test cases.
Let me know, if more information or help with this PR is needed.
Diffstat (limited to 'CHANGELOG.md')
0 files changed, 0 insertions, 0 deletions