Code review

This commit is contained in:
Anantachai Saothong (Manta) 2023-12-28 23:44:54 +07:00
parent 70da331cd2
commit 241a772d55
3 changed files with 3 additions and 3 deletions

View file

@ -18,7 +18,7 @@ export function getNodeVersionFromFile(versionFilePath: string): string | null {
const manifest = JSON.parse(contents);
// Presume package.json file.
if (typeof manifest === 'object' && manifest !== null) {
if (typeof manifest === 'object' && !!manifest) {
// Support Volta.
// See https://docs.volta.sh/guide/understanding#managing-your-project
if (manifest.volta?.node) {