mirror of
https://github.com/tdurieux/anonymous_github.git
synced 2026-07-09 07:07:50 +02:00
check repo status for github page
This commit is contained in:
@@ -17,6 +17,13 @@ async function webView(req, res) {
|
|||||||
if (!repoConfig.options.pageSource) {
|
if (!repoConfig.options.pageSource) {
|
||||||
throw "page_not_activated";
|
throw "page_not_activated";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (repoConfig.status == "expired") {
|
||||||
|
throw "repository_expired";
|
||||||
|
}
|
||||||
|
if (repoConfig.status == "removed") {
|
||||||
|
throw "repository_expired";
|
||||||
|
}
|
||||||
|
|
||||||
if (repoConfig.options.pageSource.branch != repoConfig.branch) {
|
if (repoConfig.options.pageSource.branch != repoConfig.branch) {
|
||||||
throw "page_not_supported_on_different_branch";
|
throw "page_not_supported_on_different_branch";
|
||||||
|
|||||||
Reference in New Issue
Block a user