File tree Expand file tree Collapse file tree 1 file changed +2
-6
lines changed Expand file tree Collapse file tree 1 file changed +2
-6
lines changed Original file line number Diff line number Diff line change @@ -235,7 +235,7 @@ fn get_metadata_from_result(mut context: Option<&mut Context>, result: &mut Valu
235235 }
236236 if let Some ( ref mut context) = context {
237237 if key == "_restartRequired" {
238- if let Some ( restart_required) = serde_json:: from_value :: < Vec < RestartRequired > > ( value. clone ( ) ) . ok ( ) {
238+ if let Ok ( restart_required) = serde_json:: from_value :: < Vec < RestartRequired > > ( value. clone ( ) ) {
239239 context. restart_required . get_or_insert_with ( Vec :: new) . extend ( restart_required) ;
240240 } else {
241241 warn ! ( "{}" , t!( "configure.mod.metadataRestartRequiredInvalid" , value = value) ) ;
@@ -775,11 +775,7 @@ impl Configurator {
775775 end_datetime : Some ( end_datetime. to_rfc3339 ( ) ) ,
776776 duration : Some ( end_datetime. signed_duration_since ( self . context . start_datetime ) . to_string ( ) ) ,
777777 security_context : Some ( self . context . security_context . clone ( ) ) ,
778- restart_required : if let Some ( restart_required) = self . context . restart_required . clone ( ) {
779- Some ( restart_required)
780- } else {
781- None
782- } ,
778+ restart_required : self . context . restart_required . clone ( ) ,
783779 }
784780 ) ,
785781 other : Map :: new ( ) ,
You can’t perform that action at this time.
0 commit comments