We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8a08cb8 commit 0fa4832Copy full SHA for 0fa4832
2 files changed
.changeset/strong-colts-hang.md
@@ -0,0 +1,5 @@
1
+---
2
+"astro": patch
3
4
+
5
+Fix "Cannot read properties of null" error in CLI code
packages/astro/src/cli/telemetry/index.ts
@@ -9,7 +9,7 @@ interface TelemetryOptions {
9
}
10
11
export async function notify() {
12
- const packageManager = (await whichPm(process.cwd())).name ?? 'npm';
+ const packageManager = (await whichPm(process.cwd()))?.name ?? 'npm';
13
await telemetry.notify(() => {
14
console.log(msg.telemetryNotice(packageManager) + '\n');
15
return true;
0 commit comments