File tree Expand file tree Collapse file tree 2 files changed +9
-9
lines changed Expand file tree Collapse file tree 2 files changed +9
-9
lines changed Original file line number Diff line number Diff line change @@ -62,10 +62,10 @@ impl Socket {
6262 match serde_json:: from_str :: < Message > ( & line) {
6363 Ok ( msg) => {
6464 info ! ( message = ?msg, "received message" ) ;
65- if let Message :: Ready { port } = msg {
66- if let Some ( tx) = port_tx. take ( ) {
67- let _ = tx . send ( port ) ;
68- }
65+ if let Message :: Ready { port } = msg
66+ && let Some ( tx) = port_tx. take ( )
67+ {
68+ let _ = tx . send ( port ) ;
6969 }
7070 }
7171 Err ( e) => info ! ( error = %e, "failed to parse message" ) ,
Original file line number Diff line number Diff line change @@ -81,11 +81,11 @@ impl Process {
8181
8282impl Drop for Process {
8383 fn drop ( & mut self ) {
84- if let Some ( mut child) = self . child . take ( ) {
85- if let Some ( pid) = child. id ( ) {
86- info ! ( pid , "dropping runtime, killing process" ) ;
87- let _ = child . start_kill ( ) ;
88- }
84+ if let Some ( mut child) = self . child . take ( )
85+ && let Some ( pid) = child. id ( )
86+ {
87+ info ! ( pid , "dropping runtime, killing process" ) ;
88+ let _ = child . start_kill ( ) ;
8989 }
9090 }
9191}
You can’t perform that action at this time.
0 commit comments