@@ -48,14 +48,13 @@ struct Link {
4848
4949impl Link {
5050 fn new ( global_props : & DictRef ) -> Option < Self > {
51- if let ( Some ( link_output_node) , Some ( link_input_node) ) = (
52- global_props
53- . get ( & keys:: LINK_OUTPUT_NODE )
54- . and_then ( |s| s. parse ( ) . ok ( ) ) ,
55- global_props
51+ if let Some ( link_output_node) = global_props
52+ . get ( & keys:: LINK_OUTPUT_NODE )
53+ . and_then ( |s| s. parse ( ) . ok ( ) )
54+ && let Some ( link_input_node) = global_props
5655 . get ( & keys:: LINK_INPUT_NODE )
57- . and_then ( |s| s. parse ( ) . ok ( ) ) ,
58- ) {
56+ . and_then ( |s| s. parse ( ) . ok ( ) )
57+ {
5958 Some ( Self {
6059 link_output_node,
6160 link_input_node,
@@ -221,10 +220,9 @@ impl PrivacyMonitor for Monitor<'_> {
221220 ..
222221 } in data. links . values ( ) . sorted ( ) . dedup ( )
223222 {
224- if let ( Some ( output_node) , Some ( input_node) ) = (
225- data. nodes . get ( link_output_node) ,
226- data. nodes . get ( link_input_node) ,
227- ) && input_node. media_class != Some ( "Audio/Sink" . into ( ) )
223+ if let Some ( output_node) = data. nodes . get ( link_output_node)
224+ && let Some ( input_node) = data. nodes . get ( link_input_node)
225+ && input_node. media_class != Some ( "Audio/Sink" . into ( ) )
228226 && !self . config . exclude_output . contains ( & output_node. name )
229227 && !self . config . exclude_input . contains ( & input_node. name )
230228 {
0 commit comments