@@ -201,7 +201,7 @@ impl TryFrom<&str> for CellSelection {
201201pub struct Options {
202202 pub location : location:: Location ,
203203 pub elevation : Option < Elevation > ,
204- /// Attributes to request for minutely_15 forecast
204+ /// Attributes to request for ` minutely_15` forecast
205205 pub minutely_15 : Vec < String > ,
206206 /// Attributes to request in hourly intervals
207207 pub hourly : Vec < String > ,
@@ -281,7 +281,7 @@ impl Options {
281281 if let Some ( v) = self . past_days {
282282 params. push ( ( "past_days" . into ( ) , v. to_string ( ) ) ) ;
283283 }
284-
284+
285285 if let Some ( v) = self . forecast_minutely_15 {
286286 params. push ( ( "forecast_minutely_15" . into ( ) , v. to_string ( ) ) ) ;
287287 }
@@ -401,6 +401,7 @@ impl client::Client {
401401 . await
402402 }
403403
404+ #[ allow( clippy:: too_many_lines) ]
404405 async fn request (
405406 & self ,
406407 opts : Options ,
@@ -459,17 +460,14 @@ impl client::Client {
459460 } ;
460461
461462 // Iterates on values
462- for ( k, v) in minutely_15. iter ( ) {
463+ for ( k, v) in & minutely_15 {
463464 if k == "time" {
464465 continue ;
465466 }
466467
467468 let mut item = ForecastResultItem :: default ( ) ;
468- let v_arr = match v. as_array ( ) {
469- Some ( v) => v,
470- None => {
471- return Err ( "cannot decode properly json input" . into ( ) ) ;
472- }
469+ let Some ( v_arr) = v. as_array ( ) else {
470+ return Err ( "cannot decode properly json input" . into ( ) ) ;
473471 } ;
474472
475473 let v_val = v_arr[ idx] . clone ( ) ;
0 commit comments