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

Commit aace4fc

Browse files
committed
Removed redundant || typeof(T) == typeof(string)
1 parent a97aef7 commit aace4fc

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/ServiceStack.OrmLite/OrmLiteSPStatement.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ public OrmLiteSPStatement(IDbCommand cmd)
1717

1818
public List<T> ConvertToList<T>()
1919
{
20-
if ((typeof(T).IsPrimitive) || (typeof(T) == typeof(string)) || (typeof(T) == typeof(String)))
20+
if (typeof(T).IsPrimitive || typeof(T) == typeof(string))
2121
throw new Exception("Type " + typeof(T).Name + " is a primitive type. Use ConvertScalarToList function.");
2222

2323
IDataReader reader = null;
@@ -55,7 +55,7 @@ public List<T> ConvertToScalarList<T>()
5555

5656
public T ConvertTo<T>()
5757
{
58-
if ((typeof(T).IsPrimitive) || (typeof(T) == typeof(string)) || (typeof(T) == typeof(String)))
58+
if (typeof(T).IsPrimitive || typeof(T) == typeof(string))
5959
throw new Exception("Type " + typeof(T).Name + " is a primitive type. Use ConvertScalarTo function.");
6060

6161
IDataReader reader = null;

0 commit comments

Comments
 (0)