Skip to content

Commit

Permalink
Change GameParty size types to longs. (discord-net#955)
Browse files Browse the repository at this point in the history
  • Loading branch information
AntiTcb authored and FiniteReality committed May 5, 2018
1 parent 76168c3 commit 4083841
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 9 deletions.
8 changes: 4 additions & 4 deletions src/Discord.Net.Core/Entities/Activities/GameParty.cs
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
namespace Discord
namespace Discord
{
public class GameParty
{
internal GameParty() { }

public string Id { get; internal set; }
public int Members { get; internal set; }
public int Capacity { get; internal set; }
public long Members { get; internal set; }
public long Capacity { get; internal set; }
}
}
}
6 changes: 3 additions & 3 deletions src/Discord.Net.Rest/API/Common/GameParty.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
using Newtonsoft.Json;
using Newtonsoft.Json;

namespace Discord.API
{
Expand All @@ -7,6 +7,6 @@ internal class GameParty
[JsonProperty("id")]
public string Id { get; set; }
[JsonProperty("size")]
public int[] Size { get; set; }
public long[] Size { get; set; }
}
}
}
4 changes: 2 additions & 2 deletions src/Discord.Net.WebSocket/Extensions/EntityExtensions.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
namespace Discord.WebSocket
namespace Discord.WebSocket
{
internal static class EntityExtensions
{
Expand Down Expand Up @@ -56,7 +56,7 @@ public static GameAsset[] ToEntity(this API.GameAssets model, ulong appId)
public static GameParty ToEntity(this API.GameParty model)
{
// Discord will probably send bad data since they don't validate anything
int current = 0, cap = 0;
long current = 0, cap = 0;
if (model.Size?.Length == 2)
{
current = model.Size[0];
Expand Down

0 comments on commit 4083841

Please sign in to comment.