fix random panic found while testing

pull/11492/head
Vulpesx 3 months ago
parent 6c2b4ce26e
commit 6336ab43b3
No known key found for this signature in database
GPG Key ID: 16151F7622E4957D

@ -287,7 +287,7 @@ fn execution_pause_indicator<'doc>(
) -> GutterFn<'doc> { ) -> GutterFn<'doc> {
let style = theme.get("ui.debug.active"); let style = theme.get("ui.debug.active");
let current_stack_frame = editor.current_stack_frame(); let current_stack_frame = editor.current_stack_frame();
let frame_line = current_stack_frame.map(|frame| frame.line - 1); let frame_line = current_stack_frame.and_then(|frame| frame.line.checked_sub(1));
let frame_source_path = current_stack_frame.map(|frame| { let frame_source_path = current_stack_frame.map(|frame| {
frame frame
.source .source

Loading…
Cancel
Save