Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: use censor to cure names with slurs #65

Open
wants to merge 10 commits into
base: main
Choose a base branch
from
Open

feat: use censor to cure names with slurs #65

wants to merge 10 commits into from

Conversation

Ushie
Copy link
Member

@Ushie Ushie commented Apr 11, 2023

No description provided.

Copy link
Member

@oSumAtrIX oSumAtrIX left a comment

Choose a reason for hiding this comment

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

If this PR is not complete yet, mark it as a draft.

src/utils/decancer.rs Outdated Show resolved Hide resolved
src/utils/decancer.rs Outdated Show resolved Hide resolved
@Ushie
Copy link
Member Author

Ushie commented Apr 12, 2023

If this PR is not complete yet, mark it as a draft.

It is complete

Copy link

@badawoll badawoll left a comment

Choose a reason for hiding this comment

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

IMO the word ass should be excluded from the list, as it filters benign words such as pass and class, which, given the context of the server, are to be expected in nicknames/usernames.

@Ushie Ushie requested a review from oSumAtrIX April 18, 2023 16:44
@Ushie
Copy link
Member Author

Ushie commented Apr 18, 2023

IMO the word ass should be excluded from the list, as it filters benign words such as pass and class, which, given the context of the server, are to be expected in nicknames/usernames.

I dont believe words like that will be effected, but I'm all for excluding ass

@Ushie
Copy link
Member Author

Ushie commented May 11, 2023

@oSumAtrIX can you review?

@badawoll
Copy link

IMO the word ass should be excluded from the list, as it filters benign words such as pass and class, which, given the context of the server, are to be expected in nicknames/usernames.

I dont believe words like that will be effected, but I'm all for excluding ass

use censor::*;

fn main() {
    let censor = Censor::Standard;
    println!("{}", censor.check("passport"));
}

from my testing, this code returns true. But anyway, such edge-cases are limited pretty much just to the word ass, I've done some grepping through dictionaries and couldn't find a similar case for other blacklisted words.

src/utils/decancer.rs Outdated Show resolved Hide resolved
src/utils/decancer.rs Outdated Show resolved Hide resolved
@Ushie Ushie force-pushed the feat/censor branch 3 times, most recently from 3395c32 to 2a24fe5 Compare May 14, 2023 22:44
@oSumAtrIX
Copy link
Member

@Ushie Please check if everything works correctly.

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.

None yet

3 participants