File tree Expand file tree Collapse file tree 2 files changed +5
-5
lines changed
src/EFCore.PG/Query/ExpressionTranslators/Internal Expand file tree Collapse file tree 2 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -27,8 +27,8 @@ public class NpgsqlDateTimeMemberTranslator : IMemberTranslator
2727 public NpgsqlDateTimeMemberTranslator ( IRelationalTypeMappingSource typeMappingSource , NpgsqlSqlExpressionFactory sqlExpressionFactory )
2828 {
2929 _typeMappingSource = typeMappingSource ;
30- _timestampMapping = typeMappingSource . FindMapping ( "timestamp without time zone" ) ! ;
31- _timestampTzMapping = typeMappingSource . FindMapping ( "timestamp with time zone" ) ! ;
30+ _timestampMapping = typeMappingSource . FindMapping ( typeof ( DateTime ) , "timestamp without time zone" ) ! ;
31+ _timestampTzMapping = typeMappingSource . FindMapping ( typeof ( DateTime ) , "timestamp with time zone" ) ! ;
3232 _sqlExpressionFactory = sqlExpressionFactory ;
3333 }
3434
Original file line number Diff line number Diff line change @@ -113,9 +113,9 @@ public NpgsqlDateTimeMethodTranslator(
113113 {
114114 _typeMappingSource = typeMappingSource ;
115115 _sqlExpressionFactory = sqlExpressionFactory ;
116- _timestampMapping = typeMappingSource . FindMapping ( "timestamp without time zone" ) ! ;
117- _timestampTzMapping = typeMappingSource . FindMapping ( "timestamp with time zone" ) ! ;
118- _intervalMapping = typeMappingSource . FindMapping ( "interval" ) ! ;
116+ _timestampMapping = typeMappingSource . FindMapping ( typeof ( DateTime ) , "timestamp without time zone" ) ! ;
117+ _timestampTzMapping = typeMappingSource . FindMapping ( typeof ( DateTime ) , "timestamp with time zone" ) ! ;
118+ _intervalMapping = typeMappingSource . FindMapping ( typeof ( TimeSpan ) , "interval" ) ! ;
119119 _textMapping = typeMappingSource . FindMapping ( "text" ) ! ;
120120 }
121121
You can’t perform that action at this time.
0 commit comments