Add feature to support 14 days and 1 year bans. fixes: #1527 - #1530
Merged
Alathreon merged 2 commits intoJul 28, 2026
Conversation
Zabuzard
requested changes
Jul 25, 2026
Alathreon
requested changes
Jul 25, 2026
KonstantineVashalomidze
force-pushed
the
feature/add-14-days-and-1-year-ban-option
branch
from
July 26, 2026 09:16
f5cbed3 to
28b14cb
Compare
Alathreon
previously approved these changes
Jul 26, 2026
Zabuzard
previously approved these changes
Jul 27, 2026
Member
|
Looks liike the line is too loong or something. Can you run spotless quickly, thanks. |
KonstantineVashalomidze
dismissed stale reviews from Zabuzard and Alathreon
via
July 27, 2026 06:41
92c3d03
Contributor
Author
@Zabuzard Done. spotless check passes locally. |
Zabuzard
approved these changes
Jul 27, 2026
Alathreon
approved these changes
Jul 28, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
fixes: #1527
New feature was added for admins. Admins can now also ban with durations 14 days or 1 year.
The following now looks like this:

Testing was done manually. I invited my friend into my test server and banned him for 14 days and 1 year. He was banned and then I have advanced system time further than 14 days and 1 year. Ban was revoked and after routine run he was unbanned.
Note that logs are within the same console since, I have just reloaded the project with Intellij devtools feature since I had problems with certificate when running app from scratch.
EDIT:
I have made changes as @Zabuzard and @Alathreon suggested. Since
.plus(...)method doesn't support years, I had to convert number of years into number of days and use unit ofDAYSto calculate ban period.EDIT 2:
We have decided just to have 365 days option inserted instead of one 1 year.