diff --git a/AmalgamationTool/DynamORM.Amalgamation.cs b/AmalgamationTool/DynamORM.Amalgamation.cs index 09044dd..4811c80 100644 --- a/AmalgamationTool/DynamORM.Amalgamation.cs +++ b/AmalgamationTool/DynamORM.Amalgamation.cs @@ -5465,7 +5465,7 @@ namespace DynamORM mainResult = cache.EnumerateReader().ToList(); } - else if (argType.IsValueType || types[0] == typeof(string)) + else if (argType.IsValueType || argType == typeof(string)) { Type listType = typeof(List<>).MakeGenericType(new Type[] { argType }); IList listInstance = (IList)Activator.CreateInstance(listType); @@ -5481,7 +5481,7 @@ namespace DynamORM mainResult = listInstance; } - else if (types[0] == typeof(Guid)) + else if (argType == typeof(Guid)) { Type listType = typeof(List<>).MakeGenericType(new Type[] { argType }); IList listInstance = (IList)Activator.CreateInstance(listType); diff --git a/DynamORM/DynamicProcedureInvoker.cs b/DynamORM/DynamicProcedureInvoker.cs index 64b8bb1..1f10840 100644 --- a/DynamORM/DynamicProcedureInvoker.cs +++ b/DynamORM/DynamicProcedureInvoker.cs @@ -203,7 +203,7 @@ namespace DynamORM mainResult = cache.EnumerateReader().ToList(); } - else if (argType.IsValueType || types[0] == typeof(string)) + else if (argType.IsValueType || argType == typeof(string)) { Type listType = typeof(List<>).MakeGenericType(new Type[] { argType }); IList listInstance = (IList)Activator.CreateInstance(listType); @@ -219,7 +219,7 @@ namespace DynamORM mainResult = listInstance; } - else if (types[0] == typeof(Guid)) + else if (argType == typeof(Guid)) { Type listType = typeof(List<>).MakeGenericType(new Type[] { argType }); IList listInstance = (IList)Activator.CreateInstance(listType);