예제 #1
0
        public RestWebhookClient(RestWebhook webhook, ILogger logger = null, IJsonSerializer serializer = null) : this(logger, serializer)
        {
            if (webhook == null)
            {
                throw new ArgumentNullException(nameof(webhook));
            }

            Id    = webhook.Id;
            Token = webhook.Token;
            Webhook.SetValue(webhook);
        }
예제 #2
0
 public RestWebhookClient(RestWebhook webhook)
     : this((webhook ?? throw new ArgumentNullException(nameof(webhook))).Client, webhook.Id, webhook.Token)