Skip to content

Commit

Permalink
Fix null pointer dereference in GetLocalSdkPackage
Browse files Browse the repository at this point in the history
  • Loading branch information
bytemain committed May 31, 2024
1 parent 9bcc064 commit 8ec27d2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion internal/sdk.go
Original file line number Diff line number Diff line change
Expand Up @@ -599,7 +599,7 @@ func (b *Sdk) GetLocalSdkPackage(version Version) (*Package, error) {
}
main := items[b.Plugin.Name]
delete(items, b.Plugin.Name)
if main.Path == "" {
if main == nil {
return nil, errors.New("main sdk not found")
}
var additions []*Info
Expand Down

0 comments on commit 8ec27d2

Please sign in to comment.