mirror of
https://github.com/tdurieux/anonymous_github.git
synced 2026-02-12 18:32:44 +00:00
fix: hot fix, replace repoID by repoId
This commit is contained in:
@@ -331,11 +331,11 @@ angular
|
||||
current = current[0].child;
|
||||
}
|
||||
name = test;
|
||||
if (size > 0) {
|
||||
if (size >= 0) {
|
||||
dir = false;
|
||||
}
|
||||
}
|
||||
if (size) {
|
||||
if (size != null) {
|
||||
size = `Size: ${humanFileSize(size || 0)}`;
|
||||
} else {
|
||||
size = "";
|
||||
|
||||
2
public/script/bundle.min.js
vendored
2
public/script/bundle.min.js
vendored
File diff suppressed because one or more lines are too long
@@ -485,7 +485,7 @@ export default class Repository {
|
||||
}
|
||||
// remove cache
|
||||
await Promise.all([
|
||||
FileModel.deleteMany({ repoID: this.repoId }).exec(),
|
||||
FileModel.deleteMany({ repoId: this.repoId }).exec(),
|
||||
this.removeCache(),
|
||||
]);
|
||||
console.log(`[RESET] ${this._model.repoId} has been reset`);
|
||||
|
||||
@@ -152,9 +152,7 @@ export default class FileSystem extends StorageBase {
|
||||
try {
|
||||
const stats = await fs.promises.stat(filePath);
|
||||
if (stats.isDirectory()) {
|
||||
output2.push(
|
||||
new FileModel({ name: file, path: dir, repoID: repoId })
|
||||
);
|
||||
output2.push(new FileModel({ name: file, path: dir, repoId }));
|
||||
output2.push(
|
||||
...(await this.listFiles(repoId, join(dir, file), opt))
|
||||
);
|
||||
@@ -169,7 +167,7 @@ export default class FileSystem extends StorageBase {
|
||||
new FileModel({
|
||||
name: file,
|
||||
path: dir,
|
||||
repoID: repoId,
|
||||
repoId: repoId,
|
||||
size: stats.size,
|
||||
sha: stats.ino.toString(),
|
||||
})
|
||||
|
||||
@@ -272,7 +272,7 @@ export default class S3Storage extends StorageBase {
|
||||
new FileModel({
|
||||
name: basename(f.Key),
|
||||
path: dirname(f.Key),
|
||||
repoID: repoId,
|
||||
repoId,
|
||||
size: f.Size,
|
||||
sha: f.ETag,
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user