Skip to content
Permalink
Browse files

Using unwrap() as suggested in review.

  • Loading branch information
Adenilson committed Apr 13, 2015
1 parent d2b7cbd commit a233cb5ef9e462ce644df6cd02f92ddc3b1166f1
Showing with 5 additions and 5 deletions.
  1. +2 −2 components/devtools/actors/timeline.rs
  2. +1 −1 components/script/dom/window.rs
  3. +2 −2 components/script/script_task.rs
@@ -214,7 +214,7 @@ impl Actor for TimelineActor {
**self.is_recording.lock().as_mut().unwrap() = true;

let (tx, rx) = channel::<TimelineMarker>();
let _ = self.script_sender.send(SetTimelineMarkers(self.pipeline, self.marker_types.clone(), tx));
self.script_sender.send(SetTimelineMarkers(self.pipeline, self.marker_types.clone(), tx)).unwrap();

*self.stream.borrow_mut() = stream.try_clone().ok();

@@ -254,7 +254,7 @@ impl Actor for TimelineActor {
};

stream.write_json_packet(&msg);
let _ = self.script_sender.send(DropTimelineMarkers(self.pipeline, self.marker_types.clone()));
self.script_sender.send(DropTimelineMarkers(self.pipeline, self.marker_types.clone())).unwrap();

if let Some(ref actor_name) = *self.framerate_actor.borrow() {
registry.drop_actor_later(actor_name.clone());
@@ -805,7 +805,7 @@ impl<'a> WindowHelpers for JSRef<'a, Window> {
fn emit_timeline_marker(self, marker: TimelineMarker) {
let sender = self.devtools_marker_sender.borrow();
let sender = sender.as_ref().expect("There is no marker sender");
let _ = sender.send(marker);
sender.send(marker).unwrap();
}

fn set_devtools_timeline_marker(self, marker: TimelineMarkerType, reply: Sender<TimelineMarker>) {
@@ -1017,7 +1017,7 @@ impl ScriptTask {
match self.page {
PageToRemove::Root => *self.script_task.page.borrow_mut() = None,
PageToRemove::Child(id) => {
let _ = self.script_task.root_page().remove(id);
self.script_task.root_page().remove(id).unwrap();
}
}
}
@@ -1349,7 +1349,7 @@ impl ScriptTask {
fn emit_timeline_marker(&self, marker: TimelineMarker) {
let sender = self.devtools_marker_sender.borrow();
let sender = sender.as_ref().expect("There is no marker sender");
let _ = sender.send(marker);
sender.send(marker).unwrap();
}

pub fn set_devtools_timeline_marker(&self, marker: TimelineMarkerType, reply: Sender<TimelineMarker>) {

0 comments on commit a233cb5

Please sign in to comment.
You can’t perform that action at this time.