Skip to content

Commit 1027df2

Browse files
committed
UnitSystem: Remove #if PORTABLE45 section
Project removed
1 parent 40b1c53 commit 1027df2

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

UnitsNet/CustomCode/UnitSystem.cs

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -164,13 +164,9 @@ public void MapUnitToAbbreviation<TUnit>(TUnit unit, params string[] abbreviatio
164164
[PublicAPI]
165165
public void MapUnitToAbbreviation(Type unitType, int unitValue, [NotNull] params string[] abbreviations)
166166
{
167-
#if PORTABLE45
168-
if (System.Reflection.IntrospectionExtensions.GetTypeInfo(unitType).IsEnum)
169-
throw new ArgumentException("Must be an enum type.", nameof(unitType));
170-
#else
171167
if (!unitType.IsEnum)
172168
throw new ArgumentException("Must be an enum type.", nameof(unitType));
173-
#endif
169+
174170
if (abbreviations == null)
175171
throw new ArgumentNullException(nameof(abbreviations));
176172

0 commit comments

Comments
 (0)