-
Notifications
You must be signed in to change notification settings - Fork 62
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
BUG: invalid user|org / project name #154
Labels
Comments
Indeed some form validation would go a long way. |
|
I've created the following function to check the username and repository values: defp user_valid?(user), do: String.match?(user, ~r/^([[:alnum:]]+-)*[[:alnum:]]+$/)
defp repository_valid?(repo), do: String.match?(repo, ~r/^[[:alnum:]-_.]+$/) |
Thanks for looking at this. 👍 |
nelsonic
added a commit
that referenced
this issue
Dec 19, 2022
Fixed. #155 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Took a quick pomodoro break and looked at the Hits homepage: https://hits.dwyl.com
Noticed that there are still strange entries, e.g:
What even is that? 🤷♂️
Then there are the more innocuous but still incorrect ones:
I think we need to be more strict and actually reject requests that have invalid
user|org
orrepo
... 💭We should create a new badge e.g:
https://img.shields.io/badge/hits-invalid%20url-red?style=flat-square
Todo
The text was updated successfully, but these errors were encountered: