Skip to content

Commit f2fc998

Browse files
committed
Fix createdmessage method as it would always throw an unhanded exception if a http 200 response wasn't received
1 parent 0c34710 commit f2fc998

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

MednaNetAPIClient/Channels/Channels.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -155,7 +155,7 @@ public Channels(HttpClient client)
155155
public async Task<Models.Messages> CreateMessage(int channelId, Models.Messages message)
156156
{
157157
HttpResponseMessage response = await client.PostAsJsonAsync("api/v1/discord/channels/" + channelId.ToString() + "/messages", message);
158-
response.EnsureSuccessStatusCode();
158+
159159

160160
Models.Messages newMessage = null;
161161

0 commit comments

Comments
 (0)