mirror of
https://github.com/tdurieux/anonymous_github.git
synced 2026-05-28 03:32:25 +02:00
feat: support uppercase in commit sha
This commit is contained in:
@@ -197,7 +197,7 @@ function validateNewRepo(repoUpdate) {
|
|||||||
if (!Array.isArray(repoUpdate.terms)) {
|
if (!Array.isArray(repoUpdate.terms)) {
|
||||||
throw new AnonymousError("invalid_terms_format", repoUpdate.terms);
|
throw new AnonymousError("invalid_terms_format", repoUpdate.terms);
|
||||||
}
|
}
|
||||||
if (!/^[a-f0-9]+$/.test(repoUpdate.source.commit)) {
|
if (!/^[a-fA-F0-9]+$/.test(repoUpdate.source.commit)) {
|
||||||
throw new AnonymousError("invalid_commit_format", repoUpdate.source.commit);
|
throw new AnonymousError("invalid_commit_format", repoUpdate.source.commit);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user