Commit Graph

5 Commits

Author SHA1 Message Date
Pieter-Jan Briers
0aadba0f72 I have spent more time today cleaning up garbage than coding new shit, and I am mad (#31246)
* Fix logging of GetWebhook errors

Yeah let's just not log the error only stack trace.

* I have spent more time today cleaning up garbage than coding new shit, and I am mad

Cleans up the custom vote Discord webhook code because I *happened* to lay my eyes on how completely terrible it was and immediately found an obvious bug with it.

Also did basic QA because jesus christ: it more clearly reports pending votes, properly indicates cancelled votes, improves footer formatting, better error logging, all the usual shit.

Requires https://github.com/space-wizards/RobustToolbox/pull/5375 to avoid test failures

(cherry picked from commit 582a644c243d1c0a0ff660933e811b89024597f6)
2025-07-20 14:48:27 +10:00
Pieter-Jan Briers
9ee3fc053a Don't create new JsonSerializerOptions for every discord webhook (#31240)
*sigh*

(cherry picked from commit d63115d1f76ecbee0618b93a196ff57f49be816f)
2025-07-20 14:48:26 +10:00
Jacob
d58d615533 Add failure logging to DiscordWebhook.cs (#30835)
* Add failure logging to DiscordWebhook.cs

Add a new function that logs errors with discord webhook's http requests.

Create, Delete, and Edit functions were modified slightly to call the log function but return the same information as before.

The log function logs the error code, caller method using a simple constant (could be better), and attempts to log headers mentioned in issue #30248.

* remove extra ';'

Co-authored-by: metalgearsloth <31366439+metalgearsloth@users.noreply.github.com>

* Move header error logs to debug

---------

Co-authored-by: metalgearsloth <31366439+metalgearsloth@users.noreply.github.com>
Co-authored-by: Pieter-Jan Briers <pieterjan.briers+git@gmail.com>
(cherry picked from commit beb86fa0fec95798ecc3811a93efad3b6675ef93)
2025-07-20 14:48:26 +10:00
LankLTE
37e097f0e8 Relay custom votes to a webhook (#18561)
Co-authored-by: DrSmugleaf <DrSmugleaf@users.noreply.github.com>
Co-authored-by: DrSmugleaf <drsmugleaf@gmail.com>
2023-12-16 20:24:33 +01:00
DrSmugleaf
913c80db4a Add round end Discord pings, discord webhook API (#19468) 2023-08-24 16:50:07 -05:00