Skip to content

Commit d5e1c38

Browse files
authored
Update filebrowser.js
1 parent f501d53 commit d5e1c38

File tree

1 file changed

+5
-7
lines changed

1 file changed

+5
-7
lines changed

filebrowser.js

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1115,6 +1115,11 @@ async function renderBranchMenuHTML(renderAll) {
11151115
// get branches for repository
11161116
branchResp = await git.getBranches(treeLoc);
11171117

1118+
// if repo dosen't exist, return
1119+
if (branchResp.message) {
1120+
return;
1121+
}
1122+
11181123
// clean resp and save only relevant fields
11191124
const cleanedResp = branchResp.map(branch => {
11201125
return { name: branch.name, commit: { sha: branch.commit.sha } };
@@ -1124,13 +1129,6 @@ async function renderBranchMenuHTML(renderAll) {
11241129
updateModRepoBranches(fullName, cleanedResp);
11251130

11261131
}
1127-
1128-
// if repo dosen't exist, return
1129-
if (branchResp.message) {
1130-
1131-
return;
1132-
1133-
}
11341132

11351133
}
11361134

0 commit comments

Comments
 (0)