feat(webhooks): add all events except group member events

This commit is contained in:
spiral
2021-11-19 11:37:50 -05:00
parent f071485a82
commit 7b9d2a4e5e
8 changed files with 156 additions and 20 deletions

View File

@@ -1,5 +1,7 @@
using SqlKata;
using Newtonsoft.Json.Linq;
namespace PluralKit.Core
{
public class AccountPatch: PatchObject
@@ -9,5 +11,15 @@ namespace PluralKit.Core
public override Query Apply(Query q) => q.ApplyPatch(wrapper => wrapper
.With("allow_autoproxy", AllowAutoproxy)
);
public JObject ToJson()
{
var o = new JObject();
if (AllowAutoproxy.IsPresent)
o.Add("allow_autoproxy", AllowAutoproxy.Value);
return o;
}
}
}