Skip to content

Commit aa63971

Browse files
committed
fixup! Let driver handle datetimes automatically
1 parent 0aff2af commit aa63971

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/NHibernate/Driver/NpgsqlDriver.cs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,10 +82,12 @@ protected override void InitializeParameter(DbParameter dbParam, string name, Sq
8282

8383
// Prior to v3, Npgsql was expecting DateTime for time.
8484
// https://github.com/npgsql/npgsql/issues/347
85-
public override bool RequiresTimeSpanForTime => (DriverVersion?.Major ?? 3) >= 3;
85+
public override bool RequiresTimeSpanForTime => DriverVersionMajor >= 3;
8686

8787
public override bool HasDelayedDistributedTransactionCompletion => true;
8888

8989
System.Type IEmbeddedBatcherFactoryProvider.BatcherFactoryClass => typeof(GenericBatchingBatcherFactory);
90+
91+
private int DriverVersionMajor => DriverVersion?.Major ?? 3;
9092
}
9193
}

0 commit comments

Comments
 (0)