Skip to content
This repository was archived by the owner on Dec 24, 2022. It is now read-only.

Commit 00766df

Browse files
committed
Add #def fix for PCL
1 parent b01143e commit 00766df

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/ServiceStack.Text/AutoMappingUtils.cs

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,11 @@ private static object ChangeValueType(object from, Type type)
7979

8080
public static object ChangeTo(this string strValue, Type type)
8181
{
82-
if (type.IsValueType && !type.IsEnum && type.HasInterface(typeof(IConvertible)))
82+
if (type.IsValueType && !type.IsEnum
83+
#if !PCL
84+
&& type.HasInterface(typeof(IConvertible))
85+
#endif
86+
)
8387
{
8488
try
8589
{

0 commit comments

Comments
 (0)