Added support for netstandard2.0 besides netstandard2.1 (multi target framework) to allow usage from UWP (netstandard 2.1 not available in UWP until .net 5)
This commit is contained in:
parent
da4855ce4f
commit
5a30d9ecfb
|
@ -22,6 +22,11 @@ namespace MediaBrowser.Model.Extensions
|
||||||
return str;
|
return str;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if NETSTANDARD2_0
|
||||||
|
char[] a = str.ToCharArray();
|
||||||
|
a[0] = char.ToUpperInvariant(a[0]);
|
||||||
|
return new string(a);
|
||||||
|
#else
|
||||||
return string.Create(
|
return string.Create(
|
||||||
str.Length,
|
str.Length,
|
||||||
str,
|
str,
|
||||||
|
@ -33,6 +38,7 @@ namespace MediaBrowser.Model.Extensions
|
||||||
chars[i] = buf[i];
|
chars[i] = buf[i];
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
<Project Sdk="Microsoft.NET.Sdk">
|
<Project Sdk="Microsoft.NET.Sdk">
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<Authors>Jellyfin Contributors</Authors>
|
<Authors>Jellyfin Contributors</Authors>
|
||||||
|
@ -8,7 +8,7 @@
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<TargetFramework>netstandard2.1</TargetFramework>
|
<TargetFrameworks>netstandard2.0;netstandard2.1</TargetFrameworks>
|
||||||
<GenerateAssemblyInfo>false</GenerateAssemblyInfo>
|
<GenerateAssemblyInfo>false</GenerateAssemblyInfo>
|
||||||
<GenerateDocumentationFile>true</GenerateDocumentationFile>
|
<GenerateDocumentationFile>true</GenerateDocumentationFile>
|
||||||
<TreatWarningsAsErrors Condition=" '$(Configuration)' == 'Release' ">true</TreatWarningsAsErrors>
|
<TreatWarningsAsErrors Condition=" '$(Configuration)' == 'Release' ">true</TreatWarningsAsErrors>
|
||||||
|
|
Loading…
Reference in New Issue
Block a user