mirror of
https://github.com/EnixCoda/Gitako.git
synced 2026-03-11 08:54:44 +00:00
fix: handle submodule which has no url or path
This commit is contained in:
parent
2dd62ed821
commit
cee198e036
1 changed files with 3 additions and 2 deletions
|
|
@ -86,8 +86,8 @@ type Parsed = {
|
|||
}
|
||||
|
||||
type ParsedModule = {
|
||||
path: string
|
||||
url: string
|
||||
path?: string
|
||||
url?: string
|
||||
}
|
||||
|
||||
function resolveGitModules(root: TreeNode, blobData: BlobData) {
|
||||
|
|
@ -102,6 +102,7 @@ function resolveGitModules(root: TreeNode, blobData: BlobData) {
|
|||
|
||||
function handleParsed(root: TreeNode, parsed: Parsed) {
|
||||
Object.values(parsed).forEach(value => {
|
||||
if (typeof value === 'string') return
|
||||
const { url, path } = value
|
||||
if (typeof url === 'string' && typeof path === 'string') {
|
||||
const node = findNode(root, path.split('/'))
|
||||
|
|
|
|||
Loading…
Reference in a new issue