Skip to content

Commit 871dcbf

Browse files
committed
Remove non-null string requirement from structs replacing enums. This was breaking deserialization if response contains empty object
1 parent 6bc4aad commit 871dcbf

24 files changed

Lines changed: 24 additions & 24 deletions

Assets/Plugins/StreamChat/Core/InternalDTO/Models/AutomodBehaviourTypeInternalDTO.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ namespace StreamChat.Core.InternalDTO.Models
2525

2626
public AutomodBehaviourTypeInternalDTO(string value)
2727
{
28-
Value = value ?? throw new System.ArgumentNullException(nameof(value));
28+
Value = value;
2929
}
3030

3131
public AutomodBehaviourTypeInternalDTO Parse(string value) => new AutomodBehaviourTypeInternalDTO(value);

Assets/Plugins/StreamChat/Core/InternalDTO/Models/AutomodTypeInternalDTO.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ namespace StreamChat.Core.InternalDTO.Models
2525

2626
public AutomodTypeInternalDTO(string value)
2727
{
28-
Value = value ?? throw new System.ArgumentNullException(nameof(value));
28+
Value = value;
2929
}
3030

3131
public AutomodTypeInternalDTO Parse(string value) => new AutomodTypeInternalDTO(value);

Assets/Plugins/StreamChat/Core/InternalDTO/Models/BlockListOptionsBehaviorInternalDTO.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ namespace StreamChat.Core.InternalDTO.Models
2525

2626
public BlockListOptionsBehaviorInternalDTO(string value)
2727
{
28-
Value = value ?? throw new System.ArgumentNullException(nameof(value));
28+
Value = value;
2929
}
3030

3131
public BlockListOptionsBehaviorInternalDTO Parse(string value) => new BlockListOptionsBehaviorInternalDTO(value);

Assets/Plugins/StreamChat/Core/InternalDTO/Models/ImageCropTypeInternalDTO.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ namespace StreamChat.Core.InternalDTO.Models
2727

2828
public ImageCropTypeInternalDTO(string value)
2929
{
30-
Value = value ?? throw new System.ArgumentNullException(nameof(value));
30+
Value = value;
3131
}
3232

3333
public ImageCropTypeInternalDTO Parse(string value) => new ImageCropTypeInternalDTO(value);

Assets/Plugins/StreamChat/Core/InternalDTO/Models/ImageResizeTypeInternalDTO.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ namespace StreamChat.Core.InternalDTO.Models
2626

2727
public ImageResizeTypeInternalDTO(string value)
2828
{
29-
Value = value ?? throw new System.ArgumentNullException(nameof(value));
29+
Value = value;
3030
}
3131

3232
public ImageResizeTypeInternalDTO Parse(string value) => new ImageResizeTypeInternalDTO(value);

Assets/Plugins/StreamChat/Core/InternalDTO/Models/MessageTypeInternalDTO.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ namespace StreamChat.Core.InternalDTO.Models
2828

2929
public MessageTypeInternalDTO(string value)
3030
{
31-
Value = value ?? throw new System.ArgumentNullException(nameof(value));
31+
Value = value;
3232
}
3333

3434
public MessageTypeInternalDTO Parse(string value) => new MessageTypeInternalDTO(value);

Assets/Plugins/StreamChat/Core/InternalDTO/Models/PushProviderTypeInternalDTO.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ namespace StreamChat.Core.InternalDTO.Models
2626

2727
public PushProviderTypeInternalDTO(string value)
2828
{
29-
Value = value ?? throw new System.ArgumentNullException(nameof(value));
29+
Value = value;
3030
}
3131

3232
public PushProviderTypeInternalDTO Parse(string value) => new PushProviderTypeInternalDTO(value);

Assets/Plugins/StreamChat/Core/InternalDTO/Requests/CreateCallRequestTypeInternalDTO.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ namespace StreamChat.Core.InternalDTO.Requests
2424

2525
public CreateCallRequestTypeInternalDTO(string value)
2626
{
27-
Value = value ?? throw new System.ArgumentNullException(nameof(value));
27+
Value = value;
2828
}
2929

3030
public CreateCallRequestTypeInternalDTO Parse(string value) => new CreateCallRequestTypeInternalDTO(value);

Assets/Plugins/StreamChat/Core/InternalDTO/Requests/CreatePollRequestVotingVisibilityInternalDTO.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ namespace StreamChat.Core.InternalDTO.Requests
2424

2525
public CreatePollRequestVotingVisibilityInternalDTO(string value)
2626
{
27-
Value = value ?? throw new System.ArgumentNullException(nameof(value));
27+
Value = value;
2828
}
2929

3030
public CreatePollRequestVotingVisibilityInternalDTO Parse(string value) => new CreatePollRequestVotingVisibilityInternalDTO(value);

Assets/Plugins/StreamChat/Core/InternalDTO/Requests/MessageRequestTypeInternalDTO.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ namespace StreamChat.Core.InternalDTO.Requests
2424

2525
public MessageRequestTypeInternalDTO(string value)
2626
{
27-
Value = value ?? throw new System.ArgumentNullException(nameof(value));
27+
Value = value;
2828
}
2929

3030
public MessageRequestTypeInternalDTO Parse(string value) => new MessageRequestTypeInternalDTO(value);

0 commit comments

Comments
 (0)