Skip to content
This repository has been archived by the owner on Feb 10, 2024. It is now read-only.

Commit

Permalink
fix(booru): filter undesirable tags
Browse files Browse the repository at this point in the history
Not only minor tags need to be filtered, but turns out that
this sort of tags are rampant around boorus, and we really,
really, need to filter them out.

Bumped to 6.0.7-3 to push.

Signed-off-by: kodehawa <david.alejandro.rubio@gmail.com>
  • Loading branch information
Kodehawa committed Nov 30, 2020
1 parent ef8425c commit 5f851a9
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 4 deletions.
2 changes: 1 addition & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,5 +42,5 @@ And module can be:
If the module isn't clear or found there, you can omit it, your message should look like:

* `Add(mine): Add new drop when mining with sparkle`
* `Fix(equip): Fix equipment disappearing if it's a full moon and you ate a taco.`
* `Fix(equip): Fix equipment disappearing if it's a full moon and you ate a taco`
* `Chore(deps): Update JDA from 4.2.0_167 to 4.2.0_178`
2 changes: 1 addition & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ plugins {
}

mainClassName = "net.kodehawa.mantarobot.MantaroBot"
def ver = new Version(major: 6, minor: 0, revision: 7)
def ver = new Version(major: 6, minor: 0, revision: "7-3")
version ver.toString()

sourceCompatibility = 15
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -597,7 +597,7 @@ public class ItemReference {
3, 1, EmoteReference.HELLFIRE_PICK.getDiscordNotation(),
"Hellfire Pickaxe", "items.hellfire_pick", "items.description.hellfire_pick",
15000, true, false,
"450;1;175;1;175;1;55;1;50;50", 3000, 1500,18, 57, 48, 61, 49, 62, 74, 73, 101, 76
"450;1;175;1;175;1;55;1;50;50", 3000, 1500, 18, 57, 48, 61, 49, 62, 74, 73, 101, 76
),

AXE = new Axe(ItemType.CHOP_AXE, 0.19f, "\uD83E\uDE93",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -221,8 +221,17 @@ public static boolean nsfwCheck(Context ctx, boolean nsfwImageboard, boolean sen

// The list of tags to exclude from searches.
private final static List<String> excludedTags = List.of(
// minor tags
"loli", "shota", "lolicon", "shotacon", "child", "underage", "young", "younger",
"under_age", "cub", "tagme", "bestiality"
"under_age", "cub",
// questionable whether this one leads to minor images or not, but
// sometimes they're tagged like this and not with any of the tags above
"flat_chest",
// tagme means it hasn't been tagged yet, so it's very unsafe to show
// you know what the other one means
"tagme", "bestiality",
// very-not-nsfl tags
"dismemberment", "death", "decapitation", "guro", "eye_socket"
);

private static boolean containsExcludedTags(List<String> tags) {
Expand Down

0 comments on commit 5f851a9

Please sign in to comment.