Skip to content

Ping Protection V2#187

Merged
SCDerox merged 10 commits intoScootKit:mainfrom
Kevinking500:ping-protection-v2
May 5, 2026
Merged

Ping Protection V2#187
SCDerox merged 10 commits intoScootKit:mainfrom
Kevinking500:ping-protection-v2

Conversation

@Kevinking500
Copy link
Copy Markdown
Contributor

@Kevinking500 Kevinking500 commented Mar 31, 2026

Ping Protection V2: QoL changes, multiple bug fixes, and a new user panel rewritten from scratch

Ping protection V2 was due for a bit of time, and it comes with multiple new (QoL) features/changes, multiple bug fixes and more. Due to the rewrite of the user panel being way more extensive, the lines of code have raised by quite the bit in some files (while some lowered). I've tried to keep the code as readable as possible in the meantime.

Full changelog:

  • [Bug fix] The action log message is now properly hidden if action logging is disabled for the moderation action
  • [Bug fix] A small capitalization mistake in the code likely made the 'deleteAllPingHistoryAfterTimeframe' do nothing - this has been fixed
  • [Bug fix] The channel types were not set properly in the config causing users to be able to select even voice channels - this has been limited to text, news and categories. Categories are now thus also supported per this support thread by Seppe, which automatically whitelists all (new) channels inside that category, thought due to AutoMod restrictions, AutoMod won't work with categories.
  • [New feature] Moderation actions can now have role-based ping limits, which could provide benefits to special roles like VIP with higher thresholds before getting punished.
  • [New feature] Categories are now supported (view the category bug fix)
  • [New feature] Link to the documentation is now provided with the error message when punishing fails (Note: The updated docs PR needs to be merged and published first to make it actually useful)
  • [QoL change] Some empty catch blocks have been updated to log the errors that are useful for debugging and is better to have logged than silently fail
  • [QoL change] The user panel has been completely reworked from scratch, including a new dropdown navigation menu instead of buttons, and more about data deletions below
  • [QoL change] Data deletions are now on a seperate page because of the change above, which also introduces a system like the staff management data deletion system: You can now select individual data to delete. Additionally, a cooldown system has been implemented here, with a 24h cooldown for a specific data deletion, and a 168h (1 week) cooldown for a full data deletion - this is to prevent abuse in data deletion, and this cooldown is user-specific

And that's PP v2!

AI usage:

  • ChatGPT: some idea's and code generations when I was too lazy to rewrite the panel logic like how I did it with SMG

Copy link
Copy Markdown
Member

@SCDerox SCDerox left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks so much for your contribution. Unfortunately, it seems like some changes occurred in the core that make your current version of this module unsupported.

Could you please run the config migration script to bring the existing configuration templates into support with the updated core requirements?

Please request a re-review once the PR is ready for review 😄

@Kevinking500
Copy link
Copy Markdown
Contributor Author

Merging the main branch actually fixed this lol, it's now back and ready for review ^^

@Kevinking500 Kevinking500 requested a review from SCDerox April 30, 2026 17:34
Comment thread modules/ping-protection/configs/configuration.json Outdated
Comment thread modules/ping-protection/configs/moderation.json Outdated
@Kevinking500
Copy link
Copy Markdown
Contributor Author

Sorry about the 2 separate commits, I am on mobile doing them on the GitHub editor. I think this should be all now ^^

@Kevinking500 Kevinking500 requested a review from SCDerox April 30, 2026 20:48
Copy link
Copy Markdown
Member

@SCDerox SCDerox left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just a few code quality issues 😄

Comment thread modules/ping-protection/ping-protection.js Outdated
Comment thread modules/ping-protection/events/interactionCreate.js Outdated
Comment thread modules/ping-protection/events/interactionCreate.js Outdated
Comment thread modules/ping-protection/events/interactionCreate.js Outdated
Comment thread modules/ping-protection/events/interactionCreate.js Outdated
Comment thread modules/ping-protection/events/interactionCreate.js Outdated
Comment thread modules/ping-protection/ping-protection.js Outdated
Comment thread modules/ping-protection/ping-protection.js Outdated
Comment thread modules/ping-protection/ping-protection.js Outdated
Comment thread modules/ping-protection/ping-protection.js Outdated
@Kevinking500
Copy link
Copy Markdown
Contributor Author

Thanks for the feedback ^^
I have replaced basically all of those (and related things) with the helper functions

@SCDerox SCDerox merged commit 73dfdea into ScootKit:main May 5, 2026
4 checks passed
@Kevinking500 Kevinking500 deleted the ping-protection-v2 branch May 5, 2026 15:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants