internal/lsp/mod: handle nil pointer exception for empty go.mod files
internal/lsp/mod: handle nil pointer exception for empty go.mod files

Fixes golang/go#41005

Change-Id: I1745c5233977d1b5603cfbb334ff087649feaa80
Reviewed-on: https://go-review.googlesource.com/c/tools/+/250657
Run-TryBot: Rebecca Stambler <d7cf11e5f299d88ea8348366a9fc4f7c335c3afa@golang.org>
Reviewed-by: Robert Findley <9179eee875d1ee628c37fb47d7e749e855ffd21f@google.com>
TryBot-Result: Gobot Gobot <66cb808b70d30c07676d5e946fee83fd561249e5@golang.org>

golang/tools,golang/tools,golang/tools,golang/tools,golang/tools