mirror of
https://github.com/FoxxMD/context-mod.git
synced 2026-04-19 03:00:07 -04:00
78 lines
2.1 KiB
Plaintext
78 lines
2.1 KiB
Plaintext
{
|
|
"runs": [
|
|
{
|
|
"checks": [
|
|
{
|
|
"name": "remove discord spam",
|
|
"notifyOnTrigger": true,
|
|
"description": "remove comments from users who are spamming discord links",
|
|
"kind": "comment",
|
|
"authorIs": {
|
|
"exclude": [
|
|
{
|
|
"isMod": true
|
|
}
|
|
]
|
|
},
|
|
"itemIs": [
|
|
{
|
|
"removed": false,
|
|
"approved": false,
|
|
}
|
|
],
|
|
"condition": "OR",
|
|
"rules": [
|
|
{
|
|
// set to false if you want to allow comments with a discord link ONLY IF
|
|
// the author doesn't have a history of spamming discord links
|
|
// -- basically allows one-off/organic discord links
|
|
"enable": true,
|
|
"name": "linkOnlySpam",
|
|
"kind": "regex",
|
|
"criteria": [
|
|
{
|
|
"name": "only link",
|
|
"regex": "/^.*(discord\\.gg\\/[\\w\\d]+)$/i",
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"condition": "AND",
|
|
"rules": [
|
|
{
|
|
"name": "linkAnywhereSpam",
|
|
"kind": "regex",
|
|
"criteria": [
|
|
{
|
|
"name": "contains link anywhere",
|
|
"regex": "/^.*(discord\\.gg\\/[\\w\\d]+).*$/i",
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"name": "linkAnywhereHistoricalSpam",
|
|
"kind": "regex",
|
|
"criteria": [
|
|
{
|
|
"name": "contains links anywhere historically",
|
|
"regex": "/^.*(discord\\.gg\\/[\\w\\d]+).*$/i",
|
|
"totalMatchThreshold": ">= 3",
|
|
"lookAt": "comments",
|
|
"window": 10
|
|
}
|
|
]
|
|
}
|
|
]
|
|
}
|
|
],
|
|
"actions": [
|
|
{
|
|
"kind": "remove"
|
|
}
|
|
]
|
|
}
|
|
]
|
|
}
|
|
],
|
|
}
|