@@ -388,18 +388,20 @@ impl Application {
388388 }
389389 Event::Breakpoint(events::Breakpoint { reason, breakpoint }) => match &reason[..] {
390390 "new" => {
391− self.editor
392− .breakpoints
393− .entry(breakpoint.source.unwrap().path.unwrap()) // TODO: no unwraps
394− .or_default()
395− .push(Breakpoint {
396− id: breakpoint.id,
397− verified: breakpoint.verified,
398− message: breakpoint.message,
399− line: breakpoint.line.unwrap().saturating_sub(1), // TODO: no unwrap
400− column: breakpoint.column,
401− ..Default::default()
402− });
391+ if let Some(source) = breakpoint.source {
392+ self.editor
393+ .breakpoints
394+ .entry(source.path.unwrap()) // TODO: no unwraps
395+ .or_default()
396+ .push(Breakpoint {
397+ id: breakpoint.id,
398+ verified: breakpoint.verified,
399+ message: breakpoint.message,
400+ line: breakpoint.line.unwrap().saturating_sub(1), // TODO: no unwrap
401+ column: breakpoint.column,
402+ ..Default::default()
403+ });
404+ }
403405 }
404406 "changed" => {
405407 for breakpoints in self.editor.breakpoints.values_mut() {