mirror of
https://github.com/ckaczor/HomeMonitor.git
synced 2026-01-13 17:22:54 -05:00
Change to .NET Standard 2.0
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
|
||||
<PropertyGroup>
|
||||
<SuppressNETCoreSdkPreviewMessage>true</SuppressNETCoreSdkPreviewMessage>
|
||||
<TargetFramework>netcoreapp2.2</TargetFramework>
|
||||
<TargetFramework>netstandard2.0</TargetFramework>
|
||||
<AssemblyName>ChrisKaczor.HomeMonitor.Weather.Models</AssemblyName>
|
||||
<RootNamespace>ChrisKaczor.HomeMonitor.Weather.Models</RootNamespace>
|
||||
<Authors>Chris Kaczor</Authors>
|
||||
|
||||
@@ -92,7 +92,7 @@ namespace ChrisKaczor.HomeMonitor.Weather.Models
|
||||
|
||||
var messageValues = messageParts.Select(m => m.Split('=')).ToDictionary(a => a[0], a => a[1]);
|
||||
|
||||
WindDirection = Enum.Parse<WindDirection>(messageValues[@"winddir"]);
|
||||
WindDirection = (WindDirection) Enum.Parse(typeof(WindDirection), messageValues[@"winddir"]);
|
||||
WindSpeed = decimal.Parse(messageValues[@"windspeedmph"]);
|
||||
Humidity = decimal.Parse(messageValues[@"humidity"]);
|
||||
HumidityTemperature = decimal.Parse(messageValues[@"tempH"]);
|
||||
|
||||
Reference in New Issue
Block a user