mirror of
https://github.com/tdurieux/anonymous_github.git
synced 2026-02-13 02:42:45 +00:00
fix: handle empty repository
This commit is contained in:
@@ -1839,10 +1839,17 @@ angular
|
||||
const path = i > 0 ? $scope.paths.slice(0, i).join("/") : "";
|
||||
await $scope.getFiles(path);
|
||||
}
|
||||
$scope.$apply(() => {
|
||||
selectFile();
|
||||
updateContent();
|
||||
});
|
||||
if ($scope.files.length == 1 && $scope.files[0].name == "") {
|
||||
$scope.files = [];
|
||||
$scope.type = "empty";
|
||||
$scope.$apply();
|
||||
} else {
|
||||
|
||||
$scope.$apply(() => {
|
||||
selectFile();
|
||||
updateContent();
|
||||
});
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
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
Reference in New Issue
Block a user