fix(project): return nil when no files found for pwsh

This commit is contained in:
Jan De Dobbeleer 2023-09-02 09:06:19 +02:00 committed by Jan De Dobbeleer
parent d3272faedd
commit 566a9d1471

View file

@ -245,6 +245,10 @@ func (n *Project) getPowerShellModuleData(_ ProjectItem) *ProjectData {
}
}
if len(content) == 0 {
return nil
}
data := &ProjectData{}
lines := strings.Split(content, "\n")