Skip to content

Commit fef57b9

Browse files
NH-4023 - Refactoring Sql Server about time type handling.
1 parent cce4b5d commit fef57b9

File tree

1 file changed

+1
-8
lines changed

1 file changed

+1
-8
lines changed

src/NHibernate/Driver/Sql2008ClientDriver.cs

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -17,13 +17,6 @@ protected override void InitializeParameter(DbParameter dbParam, string name, Sq
1717
}
1818
}
1919

20-
public override void AdjustCommand(DbCommand command)
21-
{
22-
foreach (var parameter in command.Parameters.Cast<SqlParameter>().Where(x => x.SqlDbType == SqlDbType.Time && (x.Value is DateTime)))
23-
{
24-
var dateTimeValue = (DateTime)parameter.Value;
25-
parameter.Value = dateTimeValue.TimeOfDay;
26-
}
27-
}
20+
public override bool RequiresTimeSpanForTime => true;
2821
}
2922
}

0 commit comments

Comments
 (0)