From 670c06bd2fc57783e12bf63c1e3ae9644523ca32 Mon Sep 17 00:00:00 2001 From: Marko Oldenburg Date: Tue, 13 Dec 2022 19:04:01 +0100 Subject: [PATCH] fix empty deklaration --- OpenWeatherMapAPI.pm | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/OpenWeatherMapAPI.pm b/OpenWeatherMapAPI.pm index 6a77a38..1873aba 100644 --- a/OpenWeatherMapAPI.pm +++ b/OpenWeatherMapAPI.pm @@ -492,17 +492,11 @@ sub _ProcessingRetrieveData { 'visibility' => int( sprintf( "%.1f", $data->{visibility} ) + 0.5 ), - 'dew_point' => int( - sprintf( - "%.1f", $data->{current}->{dew_point} - ) + 0.5 - ), }; } when ('onecall') { if ( !exists( $self->{cached}->{current} ) ) { - $self->{cached}->{license}{text} = 'none'; $self->{cached}->{current} = { 'temperature' => int( sprintf( "%.1f", $data->{current}->{temp} ) @@ -516,7 +510,10 @@ sub _ProcessingRetrieveData { sprintf( "%.1f", $data->{current}->{feels_like} ) + 0.5 ), - + 'dew_point' => int( + sprintf( "%.1f", + $data->{current}->{dew_point} ) + 0.5 + ), 'humidity' => $data->{current}->{humidity}, 'condition' => encode_utf8( $data->{current}->{weather}->[0]