mirror of
https://github.com/tdurieux/anonymous_github.git
synced 2026-05-16 06:49:09 +02:00
fix repository update
This commit is contained in:
@@ -57,7 +57,7 @@ router.post("/:repoId/", async (req, res) => {
|
|||||||
force: true,
|
force: true,
|
||||||
token: req.user.accessToken,
|
token: req.user.accessToken,
|
||||||
});
|
});
|
||||||
if (repoConfig.options.mode == "download") {
|
if (repoUpdate.options.mode == "download") {
|
||||||
// details.size is in kilobytes
|
// details.size is in kilobytes
|
||||||
if (details.size > config.MAX_REPO_SIZE) {
|
if (details.size > config.MAX_REPO_SIZE) {
|
||||||
return res.status(500).send({ error: "invalid_mode" });
|
return res.status(500).send({ error: "invalid_mode" });
|
||||||
@@ -99,7 +99,7 @@ router.post("/:repoId/", async (req, res) => {
|
|||||||
page: repoUpdate.options.page,
|
page: repoUpdate.options.page,
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
if (repoConfig.options.page) {
|
if (repoUpdate.options.page) {
|
||||||
data.options.pageSource = details.pageSource;
|
data.options.pageSource = details.pageSource;
|
||||||
}
|
}
|
||||||
await db.get("anonymized_repositories").updateOne(
|
await db.get("anonymized_repositories").updateOne(
|
||||||
|
|||||||
Reference in New Issue
Block a user