Skip to content

Commit 26d617a

Browse files
author
Oleksandr Poliakov
committed
fix nullreference exception
1 parent af44109 commit 26d617a

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/MongoDB.Driver/MongoCollectionSettings.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,7 @@ public IBsonSerializerRegistry SerializerRegistry
126126
/// </summary>
127127
public TimeSpan? Timeout
128128
{
129-
get { return _timeout.Value; }
129+
get { return _timeout; }
130130
set
131131
{
132132
if (_isFrozen) { throw new InvalidOperationException("MongoCollectionSettings is frozen."); }

src/MongoDB.Driver/MongoDatabaseSettings.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ public IBsonSerializerRegistry SerializerRegistry
111111
/// </summary>
112112
public TimeSpan? Timeout
113113
{
114-
get { return _timeout.Value; }
114+
get { return _timeout; }
115115
set
116116
{
117117
if (_isFrozen) { throw new InvalidOperationException("MongoCollectionSettings is frozen."); }

0 commit comments

Comments
 (0)