File tree Expand file tree Collapse file tree 1 file changed +4
-1
lines changed
src/vs/workbench/contrib/chat/browser Expand file tree Collapse file tree 1 file changed +4
-1
lines changed Original file line number Diff line number Diff line change @@ -380,7 +380,10 @@ export class LanguageModelToolsService extends Disposable implements ILanguageMo
380
380
if ( autoApproved ) {
381
381
return ;
382
382
}
383
- const setting : { sound : 'auto' | 'on' | 'off' ; announcement : 'auto' | 'off' } = this . _configurationService . getValue ( AccessibilitySignal . chatUserActionRequired . settingsKey ) ;
383
+ const setting : { sound ?: 'auto' | 'on' | 'off' ; announcement ?: 'auto' | 'off' } | undefined = this . _configurationService . getValue ( AccessibilitySignal . chatUserActionRequired . settingsKey ) ;
384
+ if ( ! setting ) {
385
+ return ;
386
+ }
384
387
const soundEnabled = setting . sound === 'on' || ( setting . sound === 'auto' && ( this . _accessibilityService . isScreenReaderOptimized ( ) || ! hasFocusedWindow ) ) ;
385
388
const announcementEnabled = this . _accessibilityService . isScreenReaderOptimized ( ) && setting . announcement === 'auto' ;
386
389
if ( soundEnabled || announcementEnabled ) {
You can’t perform that action at this time.
0 commit comments