From 0ee300be2a73c2808bb4ac9930786340fd97c21b Mon Sep 17 00:00:00 2001 From: Jason2866 Date: Fri, 13 Mar 2026 12:12:11 +0100 Subject: [PATCH] fix: avoid crash when optional is missing in svd. issue: https://github.com/platformio/platform-raspberrypi/issues/21 --- src/frontend/peripheral.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/frontend/peripheral.ts b/src/frontend/peripheral.ts index c22f221..99f7e3e 100644 --- a/src/frontend/peripheral.ts +++ b/src/frontend/peripheral.ts @@ -985,7 +985,7 @@ export class PeripheralTreeProvider implements vscode.TreeDataProvider const options: any = { name: peripheralDef.name[0], baseAddress: parseInteger(peripheralDef.baseAddress[0]), - description: peripheralDef.description[0], + description: peripheralDef.description ? peripheralDef.description[0] : '', totalLength, };