debug: null guard

This commit is contained in:
isidor 2017-06-01 15:16:46 +02:00
parent e4c130c36a
commit 7533eb39a0

View file

@ -278,8 +278,10 @@ export class DebugService implements debug.IDebugService {
}
this.focusStackFrameAndEvaluate(stackFrameToFocus).done(null, errors.onUnexpectedError);
this.windowService.getWindow().focus();
aria.alert(nls.localize('debuggingPaused', "Debugging paused, reason {0}, {1} {2}", thread.stoppedDetails.reason, stackFrameToFocus.source ? stackFrameToFocus.source.name : '', stackFrameToFocus.range.startLineNumber));
if (thread.stoppedDetails) {
this.windowService.getWindow().focus();
aria.alert(nls.localize('debuggingPaused', "Debugging paused, reason {0}, {1} {2}", thread.stoppedDetails.reason, stackFrameToFocus.source ? stackFrameToFocus.source.name : '', stackFrameToFocus.range.startLineNumber));
}
return stackFrameToFocus.openInEditor(this.editorService);
}